mirror of
https://github.com/netsurf-browser/netsurf
synced 2024-12-24 21:16:50 +03:00
Implemented download window
svn path=/trunk/netsurf/; revision=11317
This commit is contained in:
parent
633f294ce2
commit
ecc314c694
49
cocoa/DownloadWindowController.h
Normal file
49
cocoa/DownloadWindowController.h
Normal file
@ -0,0 +1,49 @@
|
||||
/*
|
||||
* Copyright 2011 Sven Weidauer <sven.weidauer@gmail.com>
|
||||
*
|
||||
* This file is part of NetSurf, http://www.netsurf-browser.org/
|
||||
*
|
||||
* NetSurf is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; version 2 of the License.
|
||||
*
|
||||
* NetSurf is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#import <Cocoa/Cocoa.h>
|
||||
|
||||
|
||||
@interface DownloadWindowController : NSWindowController {
|
||||
struct download_context *context;
|
||||
unsigned long totalSize;
|
||||
unsigned long receivedSize;
|
||||
|
||||
NSURL *url;
|
||||
NSString *mimeType;
|
||||
NSURL *saveURL;
|
||||
NSFileHandle *outputFile;
|
||||
NSMutableData *savedData;
|
||||
NSDate *startDate;
|
||||
}
|
||||
|
||||
@property (readwrite, copy, nonatomic) NSURL *URL;
|
||||
@property (readwrite, copy, nonatomic) NSString *MIMEType;
|
||||
@property (readwrite, assign, nonatomic) unsigned long totalSize;
|
||||
@property (readwrite, copy, nonatomic) NSURL *saveURL;
|
||||
@property (readwrite, assign, nonatomic) unsigned long receivedSize;
|
||||
|
||||
@property (readonly, nonatomic) NSString *fileName;
|
||||
@property (readonly, nonatomic) NSImage *icon;
|
||||
@property (readonly, nonatomic) NSString *statusText;
|
||||
|
||||
- initWithContext: (struct download_context *)ctx;
|
||||
|
||||
- (void) abort;
|
||||
|
||||
@end
|
242
cocoa/DownloadWindowController.m
Normal file
242
cocoa/DownloadWindowController.m
Normal file
@ -0,0 +1,242 @@
|
||||
/*
|
||||
* Copyright 2011 Sven Weidauer <sven.weidauer@gmail.com>
|
||||
*
|
||||
* This file is part of NetSurf, http://www.netsurf-browser.org/
|
||||
*
|
||||
* NetSurf is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; version 2 of the License.
|
||||
*
|
||||
* NetSurf is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#import "DownloadWindowController.h"
|
||||
|
||||
#import "desktop/download.h"
|
||||
|
||||
#define UNIMPL() NSLog( @"Function '%s' unimplemented", __func__ )
|
||||
|
||||
@interface DownloadWindowController ()
|
||||
|
||||
@property (readwrite, retain, nonatomic) NSFileHandle *outputFile;
|
||||
@property (readwrite, retain, nonatomic) NSMutableData *savedData;
|
||||
@property (readwrite, copy, nonatomic) NSDate *startDate;
|
||||
|
||||
- (void)savePanelDidEnd:(NSSavePanel *)sheet returnCode:(int)returnCode contextInfo:(void *)contextInfo;
|
||||
- (void)alertDidEnd:(NSAlert *)alert returnCode:(NSInteger)returnCode contextInfo:(void *)contextInfo;
|
||||
|
||||
- (BOOL) receivedData: (NSData *)data;
|
||||
|
||||
- (void) showError: (NSString *)error;
|
||||
|
||||
@end
|
||||
|
||||
|
||||
@implementation DownloadWindowController
|
||||
|
||||
- initWithContext: (struct download_context *)ctx;
|
||||
{
|
||||
if ((self = [super initWithWindowNibName: @"DownloadWindow"]) == nil) return nil;
|
||||
|
||||
context = ctx;
|
||||
totalSize = download_context_get_total_length( context );
|
||||
[self setURL: [NSURL URLWithString: [NSString stringWithUTF8String: download_context_get_url( context )]]];
|
||||
[self setMIMEType: [NSString stringWithUTF8String: download_context_get_mime_type( context )]];
|
||||
[self setStartDate: [NSDate date]];
|
||||
|
||||
return self;
|
||||
}
|
||||
|
||||
- (void) dealloc;
|
||||
{
|
||||
download_context_destroy( context );
|
||||
|
||||
[self setURL: nil];
|
||||
[self setMIMEType: nil];
|
||||
[self setSaveURL: nil];
|
||||
[self setOutputFile: nil];
|
||||
[self setSavedData: nil];
|
||||
[self setStartDate: nil];
|
||||
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
- (void) abort;
|
||||
{
|
||||
download_context_abort( context );
|
||||
}
|
||||
|
||||
- (void) askForSave;
|
||||
{
|
||||
[[NSSavePanel savePanel] beginSheetForDirectory: nil
|
||||
file: [[url path] lastPathComponent]
|
||||
modalForWindow: [self window]
|
||||
modalDelegate: self
|
||||
didEndSelector: @selector(savePanelDidEnd:returnCode:contextInfo:)
|
||||
contextInfo: NULL];
|
||||
}
|
||||
|
||||
- (void)savePanelDidEnd:(NSSavePanel *)sheet returnCode:(int)returnCode contextInfo:(void *)contextInfo;
|
||||
{
|
||||
if (returnCode == NSCancelButton) {
|
||||
[self abort];
|
||||
return;
|
||||
}
|
||||
|
||||
NSURL *targetURL = [sheet URL];
|
||||
NSString *path = [targetURL path];
|
||||
|
||||
[[NSFileManager defaultManager] createFileAtPath: path contents: nil attributes: nil];
|
||||
[self setOutputFile: [NSFileHandle fileHandleForWritingAtPath: path]];
|
||||
[self setSaveURL: targetURL];
|
||||
|
||||
NSWindow *win = [self window];
|
||||
[win setRepresentedURL: targetURL];
|
||||
[win setTitle: [self fileName]];
|
||||
|
||||
if (nil == outputFile) {
|
||||
[self performSelector: @selector(showError:) withObject: @"Cannot create file" afterDelay: 0];
|
||||
return;
|
||||
}
|
||||
|
||||
if (nil != savedData) {
|
||||
[outputFile writeData: savedData];
|
||||
[self setSavedData: nil];
|
||||
}
|
||||
}
|
||||
|
||||
- (BOOL) receivedData: (NSData *)data;
|
||||
{
|
||||
if (outputFile) {
|
||||
[outputFile writeData: data];
|
||||
} else {
|
||||
if (nil == savedData) [self setSavedData: [NSMutableData data]];
|
||||
[savedData appendData: data];
|
||||
}
|
||||
|
||||
[self setReceivedSize: receivedSize + [data length]];
|
||||
|
||||
return YES;
|
||||
}
|
||||
|
||||
- (void) showError: (NSString *)error;
|
||||
{
|
||||
NSAlert *alert = [NSAlert alertWithMessageText: @"Error" defaultButton: @"OK"
|
||||
alternateButton: nil otherButton: nil
|
||||
informativeTextWithFormat: @"%@", error];
|
||||
|
||||
[alert beginSheetModalForWindow: [self window] modalDelegate: self
|
||||
didEndSelector: @selector(alertDidEnd:returnCode:contextInfo:)
|
||||
contextInfo: NULL];
|
||||
}
|
||||
|
||||
- (void)alertDidEnd:(NSAlert *)alert returnCode:(NSInteger)returnCode contextInfo:(void *)contextInfo;
|
||||
{
|
||||
[self abort];
|
||||
}
|
||||
|
||||
#pragma mark -
|
||||
#pragma mark Properties
|
||||
|
||||
@synthesize URL = url;
|
||||
@synthesize MIMEType = mimeType;
|
||||
@synthesize totalSize;
|
||||
@synthesize saveURL;
|
||||
@synthesize outputFile;
|
||||
@synthesize savedData;
|
||||
@synthesize receivedSize;
|
||||
@synthesize startDate;
|
||||
|
||||
+ (NSSet *) keyPathsForValuesAffectingStatusText;
|
||||
{
|
||||
return [NSSet setWithObjects: @"totalSize", @"receivedSize", nil];
|
||||
}
|
||||
|
||||
static NSString *cocoa_file_size_string( float size )
|
||||
{
|
||||
if (size < 1023) return [NSString stringWithFormat:@"%1.0f bytes",size];
|
||||
|
||||
size /= 1024;
|
||||
if (size < 1023) return [NSString stringWithFormat:@"%1.1f KiB", size];
|
||||
|
||||
size /= 1024;
|
||||
if (size < 1023) return [NSString stringWithFormat:@"%1.1f MiB", size];
|
||||
|
||||
size /= 1024;
|
||||
return [NSString stringWithFormat:@"%1.1f GiB", size];
|
||||
}
|
||||
|
||||
- (NSString *) statusText;
|
||||
{
|
||||
NSString *speedString = @"";
|
||||
|
||||
float elapsedTime = [[NSDate date] timeIntervalSinceDate: startDate];
|
||||
if (elapsedTime >= 0.1) {
|
||||
float speed = (float)receivedSize / elapsedTime;
|
||||
speedString = [NSString stringWithFormat: @" (%@/s)", cocoa_file_size_string( speed )];
|
||||
}
|
||||
|
||||
return [NSString stringWithFormat: @"%@ of %@%@", cocoa_file_size_string( receivedSize ),
|
||||
cocoa_file_size_string( totalSize ), speedString];
|
||||
}
|
||||
|
||||
+ (NSSet *) keyPathsForValuesAffectingFileName;
|
||||
{
|
||||
return [NSSet setWithObject: @"saveURL"];
|
||||
}
|
||||
|
||||
- (NSString *) fileName;
|
||||
{
|
||||
return [[saveURL path] lastPathComponent];
|
||||
}
|
||||
|
||||
+ (NSSet *) keyPathsForValuesAffectingIcon;
|
||||
{
|
||||
return [NSSet setWithObject: @"saveURL"];
|
||||
}
|
||||
|
||||
- (NSImage *) icon;
|
||||
{
|
||||
return saveURL != nil ? [[NSWorkspace sharedWorkspace] iconForFile: [saveURL path]] : nil;
|
||||
}
|
||||
|
||||
|
||||
#pragma mark -
|
||||
#pragma mark NetSurf interface functions
|
||||
|
||||
struct gui_download_window *gui_download_window_create(download_context *ctx,
|
||||
struct gui_window *parent)
|
||||
{
|
||||
DownloadWindowController * const window = [[DownloadWindowController alloc] initWithContext: ctx];
|
||||
[window askForSave];
|
||||
|
||||
return (struct gui_download_window *)window;
|
||||
}
|
||||
|
||||
nserror gui_download_window_data(struct gui_download_window *dw,
|
||||
const char *data, unsigned int size)
|
||||
{
|
||||
DownloadWindowController * const window = (DownloadWindowController *)dw;
|
||||
return [window receivedData: [NSData dataWithBytes: data length: size]] ? NSERROR_OK : NSERROR_SAVE_FAILED;
|
||||
}
|
||||
|
||||
void gui_download_window_error(struct gui_download_window *dw,
|
||||
const char *error_msg)
|
||||
{
|
||||
DownloadWindowController * const window = (DownloadWindowController *)dw;
|
||||
[window showError: [NSString stringWithUTF8String: error_msg]];
|
||||
}
|
||||
|
||||
void gui_download_window_done(struct gui_download_window *dw)
|
||||
{
|
||||
DownloadWindowController * const window = (DownloadWindowController *)dw;
|
||||
[window release];
|
||||
}
|
||||
|
||||
@end
|
@ -113,6 +113,8 @@
|
||||
26AFE63F12DDEB0A005AD082 /* NetSurf.icns in Resources */ = {isa = PBXBuildFile; fileRef = 26AFE63E12DDEB0A005AD082 /* NetSurf.icns */; };
|
||||
26AFE8E412DF4200005AD082 /* ScrollableView.m in Sources */ = {isa = PBXBuildFile; fileRef = 26AFE8E312DF4200005AD082 /* ScrollableView.m */; };
|
||||
26AFE97C12DF514C005AD082 /* NetSurfAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 26AFE97B12DF514C005AD082 /* NetSurfAppDelegate.m */; };
|
||||
26AFEAEB12E04253005AD082 /* DownloadWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 26AFEAEA12E04253005AD082 /* DownloadWindowController.m */; };
|
||||
26AFEAF112E042F9005AD082 /* DownloadWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 26AFEAF012E042F9005AD082 /* DownloadWindow.xib */; };
|
||||
8D11072F0486CEB800E47090 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */; };
|
||||
/* End PBXBuildFile section */
|
||||
|
||||
@ -331,6 +333,9 @@
|
||||
26AFE8E312DF4200005AD082 /* ScrollableView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ScrollableView.m; sourceTree = "<group>"; };
|
||||
26AFE97A12DF514C005AD082 /* NetSurfAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NetSurfAppDelegate.h; sourceTree = "<group>"; };
|
||||
26AFE97B12DF514C005AD082 /* NetSurfAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = NetSurfAppDelegate.m; sourceTree = "<group>"; };
|
||||
26AFEAE912E04253005AD082 /* DownloadWindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DownloadWindowController.h; sourceTree = "<group>"; };
|
||||
26AFEAEA12E04253005AD082 /* DownloadWindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DownloadWindowController.m; sourceTree = "<group>"; };
|
||||
26AFEAF012E042F9005AD082 /* DownloadWindow.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = DownloadWindow.xib; sourceTree = "<group>"; };
|
||||
8D1107320486CEB800E47090 /* NetSurf.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = NetSurf.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
/* End PBXFileReference section */
|
||||
|
||||
@ -610,6 +615,8 @@
|
||||
26AFE8E312DF4200005AD082 /* ScrollableView.m */,
|
||||
26AFE97A12DF514C005AD082 /* NetSurfAppDelegate.h */,
|
||||
26AFE97B12DF514C005AD082 /* NetSurfAppDelegate.m */,
|
||||
26AFEAE912E04253005AD082 /* DownloadWindowController.h */,
|
||||
26AFEAEA12E04253005AD082 /* DownloadWindowController.m */,
|
||||
);
|
||||
name = cocoa;
|
||||
sourceTree = "<group>";
|
||||
@ -625,6 +632,7 @@
|
||||
265F30A712D6637E0048B600 /* NetSurf-Info.plist */,
|
||||
26121DA812D700B800E10F91 /* MainMenu.xib */,
|
||||
26121EAB12D70E0A00E10F91 /* Browser.xib */,
|
||||
26AFEAF012E042F9005AD082 /* DownloadWindow.xib */,
|
||||
);
|
||||
path = res;
|
||||
sourceTree = "<group>";
|
||||
@ -748,6 +756,7 @@
|
||||
2612266D12D7AD6800E10F91 /* adblock.css in Resources */,
|
||||
2612269112D7AE4100E10F91 /* Messages in Resources */,
|
||||
26AFE63F12DDEB0A005AD082 /* NetSurf.icns in Resources */,
|
||||
26AFEAF112E042F9005AD082 /* DownloadWindow.xib in Resources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
@ -857,6 +866,7 @@
|
||||
2622F1D712DCD84600CD5A62 /* TreeView.m in Sources */,
|
||||
26AFE8E412DF4200005AD082 /* ScrollableView.m in Sources */,
|
||||
26AFE97C12DF514C005AD082 /* NetSurfAppDelegate.m in Sources */,
|
||||
26AFEAEB12E04253005AD082 /* DownloadWindowController.m in Sources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
|
29
cocoa/gui.m
29
cocoa/gui.m
@ -252,33 +252,6 @@ void gui_window_set_scale(struct gui_window *g, float scale)
|
||||
gui_window_redraw_window( g );
|
||||
}
|
||||
|
||||
|
||||
struct gui_download_window *gui_download_window_create(download_context *ctx,
|
||||
struct gui_window *parent)
|
||||
{
|
||||
UNIMPL();
|
||||
return NULL;
|
||||
}
|
||||
|
||||
nserror gui_download_window_data(struct gui_download_window *dw,
|
||||
const char *data, unsigned int size)
|
||||
{
|
||||
UNIMPL();
|
||||
return 0;
|
||||
}
|
||||
|
||||
void gui_download_window_error(struct gui_download_window *dw,
|
||||
const char *error_msg)
|
||||
{
|
||||
UNIMPL();
|
||||
}
|
||||
|
||||
void gui_download_window_done(struct gui_download_window *dw)
|
||||
{
|
||||
UNIMPL();
|
||||
}
|
||||
|
||||
|
||||
void gui_drag_save_object(gui_save_type type, hlcache_handle *c,
|
||||
struct gui_window *g)
|
||||
{
|
||||
@ -338,8 +311,6 @@ void gui_launch_url(const char *url)
|
||||
[[NSWorkspace sharedWorkspace] openURL: [NSURL URLWithString: [NSString stringWithUTF8String: url]]];
|
||||
}
|
||||
|
||||
|
||||
|
||||
struct ssl_cert_info;
|
||||
|
||||
void gui_cert_verify(const char *url, const struct ssl_cert_info *certs,
|
||||
|
454
cocoa/res/DownloadWindow.xib
Normal file
454
cocoa/res/DownloadWindow.xib
Normal file
@ -0,0 +1,454 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="7.10">
|
||||
<data>
|
||||
<int key="IBDocument.SystemTarget">1050</int>
|
||||
<string key="IBDocument.SystemVersion">10J567</string>
|
||||
<string key="IBDocument.InterfaceBuilderVersion">804</string>
|
||||
<string key="IBDocument.AppKitVersion">1038.35</string>
|
||||
<string key="IBDocument.HIToolboxVersion">462.00</string>
|
||||
<object class="NSMutableDictionary" key="IBDocument.PluginVersions">
|
||||
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin</string>
|
||||
<string key="NS.object.0">804</string>
|
||||
</object>
|
||||
<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<integer value="2"/>
|
||||
</object>
|
||||
<object class="NSArray" key="IBDocument.PluginDependencies">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
|
||||
</object>
|
||||
<object class="NSMutableDictionary" key="IBDocument.Metadata">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<object class="NSArray" key="dict.sortedKeys" id="0">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
</object>
|
||||
<object class="NSMutableArray" key="dict.values">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
</object>
|
||||
</object>
|
||||
<object class="NSMutableArray" key="IBDocument.RootObjects" id="1000">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<object class="NSCustomObject" id="1001">
|
||||
<string key="NSClassName">DownloadWindowController</string>
|
||||
</object>
|
||||
<object class="NSCustomObject" id="1003">
|
||||
<string key="NSClassName">FirstResponder</string>
|
||||
</object>
|
||||
<object class="NSCustomObject" id="1004">
|
||||
<string key="NSClassName">NSApplication</string>
|
||||
</object>
|
||||
<object class="NSWindowTemplate" id="1005">
|
||||
<int key="NSWindowStyleMask">15</int>
|
||||
<int key="NSWindowBacking">2</int>
|
||||
<string key="NSWindowRect">{{196, 429}, {376, 90}}</string>
|
||||
<int key="NSWTFlags">544735232</int>
|
||||
<string key="NSWindowTitle">Download</string>
|
||||
<string key="NSWindowClass">NSWindow</string>
|
||||
<nil key="NSViewClass"/>
|
||||
<string key="NSWindowContentMaxSize">{1000, 90}</string>
|
||||
<string key="NSWindowContentMinSize">{330, 90}</string>
|
||||
<object class="NSView" key="NSWindowView" id="1006">
|
||||
<reference key="NSNextResponder"/>
|
||||
<int key="NSvFlags">256</int>
|
||||
<object class="NSMutableArray" key="NSSubviews">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<object class="NSProgressIndicator" id="663127685">
|
||||
<reference key="NSNextResponder" ref="1006"/>
|
||||
<int key="NSvFlags">1290</int>
|
||||
<object class="NSPSMatrix" key="NSDrawMatrix"/>
|
||||
<string key="NSFrame">{{79, 33}, {279, 20}}</string>
|
||||
<reference key="NSSuperview" ref="1006"/>
|
||||
<int key="NSpiFlags">16392</int>
|
||||
<double key="NSMaxValue">100</double>
|
||||
</object>
|
||||
<object class="NSImageView" id="454520484">
|
||||
<reference key="NSNextResponder" ref="1006"/>
|
||||
<int key="NSvFlags">268</int>
|
||||
<object class="NSMutableSet" key="NSDragTypes">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<object class="NSArray" key="set.sortedObjects">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<string>Apple PDF pasteboard type</string>
|
||||
<string>Apple PICT pasteboard type</string>
|
||||
<string>Apple PNG pasteboard type</string>
|
||||
<string>NSFilenamesPboardType</string>
|
||||
<string>NeXT Encapsulated PostScript v1.2 pasteboard type</string>
|
||||
<string>NeXT TIFF v4.0 pasteboard type</string>
|
||||
</object>
|
||||
</object>
|
||||
<string key="NSFrame">{{17, 17}, {56, 56}}</string>
|
||||
<reference key="NSSuperview" ref="1006"/>
|
||||
<bool key="NSEnabled">YES</bool>
|
||||
<object class="NSImageCell" key="NSCell" id="596224379">
|
||||
<int key="NSCellFlags">130560</int>
|
||||
<int key="NSCellFlags2">33554432</int>
|
||||
<int key="NSAlign">0</int>
|
||||
<int key="NSScale">3</int>
|
||||
<int key="NSStyle">0</int>
|
||||
<bool key="NSAnimates">NO</bool>
|
||||
</object>
|
||||
<bool key="NSEditable">YES</bool>
|
||||
</object>
|
||||
<object class="NSTextField" id="355449439">
|
||||
<reference key="NSNextResponder" ref="1006"/>
|
||||
<int key="NSvFlags">266</int>
|
||||
<string key="NSFrame">{{78, 56}, {261, 17}}</string>
|
||||
<reference key="NSSuperview" ref="1006"/>
|
||||
<bool key="NSEnabled">YES</bool>
|
||||
<object class="NSTextFieldCell" key="NSCell" id="578533771">
|
||||
<int key="NSCellFlags">68288064</int>
|
||||
<int key="NSCellFlags2">272630784</int>
|
||||
<string key="NSContents">Label</string>
|
||||
<object class="NSFont" key="NSSupport">
|
||||
<string key="NSName">LucidaGrande</string>
|
||||
<double key="NSSize">13</double>
|
||||
<int key="NSfFlags">1044</int>
|
||||
</object>
|
||||
<reference key="NSControlView" ref="355449439"/>
|
||||
<object class="NSColor" key="NSBackgroundColor" id="388192080">
|
||||
<int key="NSColorSpace">6</int>
|
||||
<string key="NSCatalogName">System</string>
|
||||
<string key="NSColorName">controlColor</string>
|
||||
<object class="NSColor" key="NSColor">
|
||||
<int key="NSColorSpace">3</int>
|
||||
<bytes key="NSWhite">MC42NjY2NjY2NjY3AA</bytes>
|
||||
</object>
|
||||
</object>
|
||||
<object class="NSColor" key="NSTextColor" id="1042936865">
|
||||
<int key="NSColorSpace">6</int>
|
||||
<string key="NSCatalogName">System</string>
|
||||
<string key="NSColorName">controlTextColor</string>
|
||||
<object class="NSColor" key="NSColor">
|
||||
<int key="NSColorSpace">3</int>
|
||||
<bytes key="NSWhite">MAA</bytes>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="NSTextField" id="1027859209">
|
||||
<reference key="NSNextResponder" ref="1006"/>
|
||||
<int key="NSvFlags">266</int>
|
||||
<string key="NSFrame">{{78, 17}, {281, 14}}</string>
|
||||
<reference key="NSSuperview" ref="1006"/>
|
||||
<bool key="NSEnabled">YES</bool>
|
||||
<object class="NSTextFieldCell" key="NSCell" id="882473472">
|
||||
<int key="NSCellFlags">68288064</int>
|
||||
<int key="NSCellFlags2">272761856</int>
|
||||
<string key="NSContents">Label</string>
|
||||
<object class="NSFont" key="NSSupport">
|
||||
<string key="NSName">LucidaGrande</string>
|
||||
<double key="NSSize">11</double>
|
||||
<int key="NSfFlags">3100</int>
|
||||
</object>
|
||||
<reference key="NSControlView" ref="1027859209"/>
|
||||
<reference key="NSBackgroundColor" ref="388192080"/>
|
||||
<reference key="NSTextColor" ref="1042936865"/>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<string key="NSFrameSize">{376, 90}</string>
|
||||
<reference key="NSSuperview"/>
|
||||
</object>
|
||||
<string key="NSScreenRect">{{0, 0}, {1680, 1028}}</string>
|
||||
<string key="NSMinSize">{330, 112}</string>
|
||||
<string key="NSMaxSize">{1000, 112}</string>
|
||||
</object>
|
||||
</object>
|
||||
<object class="IBObjectContainer" key="IBDocument.Objects">
|
||||
<object class="NSMutableArray" key="connectionRecords">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBOutletConnection" key="connection">
|
||||
<string key="label">window</string>
|
||||
<reference key="source" ref="1001"/>
|
||||
<reference key="destination" ref="1005"/>
|
||||
</object>
|
||||
<int key="connectionID">3</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBBindingConnection" key="connection">
|
||||
<string key="label">maxValue: totalSize</string>
|
||||
<reference key="source" ref="663127685"/>
|
||||
<reference key="destination" ref="1001"/>
|
||||
<object class="NSNibBindingConnector" key="connector" id="721881472">
|
||||
<reference key="NSSource" ref="663127685"/>
|
||||
<reference key="NSDestination" ref="1001"/>
|
||||
<string key="NSLabel">maxValue: totalSize</string>
|
||||
<string key="NSBinding">maxValue</string>
|
||||
<string key="NSKeyPath">totalSize</string>
|
||||
<int key="NSNibBindingConnectorVersion">2</int>
|
||||
</object>
|
||||
</object>
|
||||
<int key="connectionID">6</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBBindingConnection" key="connection">
|
||||
<string key="label">value: receivedSize</string>
|
||||
<reference key="source" ref="663127685"/>
|
||||
<reference key="destination" ref="1001"/>
|
||||
<object class="NSNibBindingConnector" key="connector">
|
||||
<reference key="NSSource" ref="663127685"/>
|
||||
<reference key="NSDestination" ref="1001"/>
|
||||
<string key="NSLabel">value: receivedSize</string>
|
||||
<string key="NSBinding">value</string>
|
||||
<string key="NSKeyPath">receivedSize</string>
|
||||
<reference key="NSPreviousConnector" ref="721881472"/>
|
||||
<int key="NSNibBindingConnectorVersion">2</int>
|
||||
</object>
|
||||
</object>
|
||||
<int key="connectionID">7</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBBindingConnection" key="connection">
|
||||
<string key="label">value: fileName</string>
|
||||
<reference key="source" ref="355449439"/>
|
||||
<reference key="destination" ref="1001"/>
|
||||
<object class="NSNibBindingConnector" key="connector">
|
||||
<reference key="NSSource" ref="355449439"/>
|
||||
<reference key="NSDestination" ref="1001"/>
|
||||
<string key="NSLabel">value: fileName</string>
|
||||
<string key="NSBinding">value</string>
|
||||
<string key="NSKeyPath">fileName</string>
|
||||
<int key="NSNibBindingConnectorVersion">2</int>
|
||||
</object>
|
||||
</object>
|
||||
<int key="connectionID">22</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBBindingConnection" key="connection">
|
||||
<string key="label">value: icon</string>
|
||||
<reference key="source" ref="454520484"/>
|
||||
<reference key="destination" ref="1001"/>
|
||||
<object class="NSNibBindingConnector" key="connector">
|
||||
<reference key="NSSource" ref="454520484"/>
|
||||
<reference key="NSDestination" ref="1001"/>
|
||||
<string key="NSLabel">value: icon</string>
|
||||
<string key="NSBinding">value</string>
|
||||
<string key="NSKeyPath">icon</string>
|
||||
<int key="NSNibBindingConnectorVersion">2</int>
|
||||
</object>
|
||||
</object>
|
||||
<int key="connectionID">23</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBBindingConnection" key="connection">
|
||||
<string key="label">value: statusText</string>
|
||||
<reference key="source" ref="1027859209"/>
|
||||
<reference key="destination" ref="1001"/>
|
||||
<object class="NSNibBindingConnector" key="connector">
|
||||
<reference key="NSSource" ref="1027859209"/>
|
||||
<reference key="NSDestination" ref="1001"/>
|
||||
<string key="NSLabel">value: statusText</string>
|
||||
<string key="NSBinding">value</string>
|
||||
<string key="NSKeyPath">statusText</string>
|
||||
<int key="NSNibBindingConnectorVersion">2</int>
|
||||
</object>
|
||||
</object>
|
||||
<int key="connectionID">24</int>
|
||||
</object>
|
||||
</object>
|
||||
<object class="IBMutableOrderedSet" key="objectRecords">
|
||||
<object class="NSArray" key="orderedObjects">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">0</int>
|
||||
<reference key="object" ref="0"/>
|
||||
<reference key="children" ref="1000"/>
|
||||
<nil key="parent"/>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">-2</int>
|
||||
<reference key="object" ref="1001"/>
|
||||
<reference key="parent" ref="0"/>
|
||||
<string key="objectName">File's Owner</string>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">-1</int>
|
||||
<reference key="object" ref="1003"/>
|
||||
<reference key="parent" ref="0"/>
|
||||
<string key="objectName">First Responder</string>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">-3</int>
|
||||
<reference key="object" ref="1004"/>
|
||||
<reference key="parent" ref="0"/>
|
||||
<string key="objectName">Application</string>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">1</int>
|
||||
<reference key="object" ref="1005"/>
|
||||
<object class="NSMutableArray" key="children">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<reference ref="1006"/>
|
||||
</object>
|
||||
<reference key="parent" ref="0"/>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">2</int>
|
||||
<reference key="object" ref="1006"/>
|
||||
<object class="NSMutableArray" key="children">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<reference ref="454520484"/>
|
||||
<reference ref="355449439"/>
|
||||
<reference ref="1027859209"/>
|
||||
<reference ref="663127685"/>
|
||||
</object>
|
||||
<reference key="parent" ref="1005"/>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">4</int>
|
||||
<reference key="object" ref="663127685"/>
|
||||
<reference key="parent" ref="1006"/>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">14</int>
|
||||
<reference key="object" ref="454520484"/>
|
||||
<object class="NSMutableArray" key="children">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<reference ref="596224379"/>
|
||||
</object>
|
||||
<reference key="parent" ref="1006"/>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">15</int>
|
||||
<reference key="object" ref="596224379"/>
|
||||
<reference key="parent" ref="454520484"/>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">16</int>
|
||||
<reference key="object" ref="355449439"/>
|
||||
<object class="NSMutableArray" key="children">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<reference ref="578533771"/>
|
||||
</object>
|
||||
<reference key="parent" ref="1006"/>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">17</int>
|
||||
<reference key="object" ref="578533771"/>
|
||||
<reference key="parent" ref="355449439"/>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">18</int>
|
||||
<reference key="object" ref="1027859209"/>
|
||||
<object class="NSMutableArray" key="children">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<reference ref="882473472"/>
|
||||
</object>
|
||||
<reference key="parent" ref="1006"/>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">19</int>
|
||||
<reference key="object" ref="882473472"/>
|
||||
<reference key="parent" ref="1027859209"/>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="NSMutableDictionary" key="flattenedProperties">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<object class="NSArray" key="dict.sortedKeys">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<string>1.IBEditorWindowLastContentRect</string>
|
||||
<string>1.IBPluginDependency</string>
|
||||
<string>1.IBWindowTemplateEditedContentRect</string>
|
||||
<string>1.NSWindowTemplate.visibleAtLaunch</string>
|
||||
<string>1.WindowOrigin</string>
|
||||
<string>1.editorWindowContentRectSynchronizationRect</string>
|
||||
<string>1.windowTemplate.hasMaxSize</string>
|
||||
<string>1.windowTemplate.hasMinSize</string>
|
||||
<string>1.windowTemplate.maxSize</string>
|
||||
<string>1.windowTemplate.minSize</string>
|
||||
<string>14.IBPluginDependency</string>
|
||||
<string>14.IBViewBoundsToFrameTransform</string>
|
||||
<string>15.IBPluginDependency</string>
|
||||
<string>16.IBPluginDependency</string>
|
||||
<string>16.IBViewBoundsToFrameTransform</string>
|
||||
<string>17.IBPluginDependency</string>
|
||||
<string>18.IBPluginDependency</string>
|
||||
<string>18.IBViewBoundsToFrameTransform</string>
|
||||
<string>19.IBPluginDependency</string>
|
||||
<string>2.IBPluginDependency</string>
|
||||
<string>4.IBPluginDependency</string>
|
||||
<string>4.IBViewBoundsToFrameTransform</string>
|
||||
</object>
|
||||
<object class="NSMutableArray" key="dict.values">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<string>{{305, 231}, {376, 90}}</string>
|
||||
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
|
||||
<string>{{305, 231}, {376, 90}}</string>
|
||||
<integer value="1"/>
|
||||
<string>{196, 240}</string>
|
||||
<string>{{202, 428}, {480, 270}}</string>
|
||||
<boolean value="YES"/>
|
||||
<boolean value="YES"/>
|
||||
<string>{1000, 90}</string>
|
||||
<string>{330, 90}</string>
|
||||
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
|
||||
<object class="NSAffineTransform">
|
||||
<bytes key="NSTransformStruct">AUGIAABBiAAAA</bytes>
|
||||
</object>
|
||||
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
|
||||
<object class="NSAffineTransform">
|
||||
<bytes key="NSTransformStruct">P4AAAL+AAABCzAAAwo4AAA</bytes>
|
||||
</object>
|
||||
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
|
||||
<object class="NSAffineTransform">
|
||||
<bytes key="NSTransformStruct">P4AAAL+AAABCnAAAwgAAAA</bytes>
|
||||
</object>
|
||||
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
|
||||
<object class="NSAffineTransform">
|
||||
<bytes key="NSTransformStruct">P4AAAL+AAABCngAAwkAAAA</bytes>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="NSMutableDictionary" key="unlocalizedProperties">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<reference key="dict.sortedKeys" ref="0"/>
|
||||
<object class="NSMutableArray" key="dict.values">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
</object>
|
||||
</object>
|
||||
<nil key="activeLocalization"/>
|
||||
<object class="NSMutableDictionary" key="localizations">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<reference key="dict.sortedKeys" ref="0"/>
|
||||
<object class="NSMutableArray" key="dict.values">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
</object>
|
||||
</object>
|
||||
<nil key="sourceID"/>
|
||||
<int key="maxID">24</int>
|
||||
</object>
|
||||
<object class="IBClassDescriber" key="IBDocument.Classes">
|
||||
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<object class="IBPartialClassDescription">
|
||||
<string key="className">DownloadWindowController</string>
|
||||
<string key="superclassName">NSWindowController</string>
|
||||
<object class="IBClassDescriptionSource" key="sourceIdentifier">
|
||||
<string key="majorKey">IBProjectSource</string>
|
||||
<string key="minorKey">DownloadWindowController.h</string>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<int key="IBDocument.localizationMode">0</int>
|
||||
<string key="IBDocument.TargetRuntimeIdentifier">IBCocoaFramework</string>
|
||||
<object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDependencyDefaults">
|
||||
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin.macosx</string>
|
||||
<integer value="1050" key="NS.object.0"/>
|
||||
</object>
|
||||
<object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies">
|
||||
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin.InterfaceBuilder3</string>
|
||||
<integer value="3000" key="NS.object.0"/>
|
||||
</object>
|
||||
<bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
|
||||
<string key="IBDocument.LastKnownRelativeProjectPath">../NetSurf.xcodeproj</string>
|
||||
<int key="IBDocument.defaultPropertyAccessControl">3</int>
|
||||
</data>
|
||||
</archive>
|
Loading…
Reference in New Issue
Block a user