From 620fd90fa7739e0a5bc23bca77033da747046c7e Mon Sep 17 00:00:00 2001 From: Sven Weidauer Date: Tue, 25 Jan 2011 17:16:20 +0000 Subject: General cleanup and warning fixes svn path=/trunk/netsurf/; revision=11486 --- cocoa/BrowserViewController.h | 2 -- cocoa/DownloadWindowController.m | 2 -- cocoa/TreeView.m | 1 - cocoa/gui.m | 4 ++-- cocoa/url.m | 5 ++--- cocoa/utils.m | 12 ------------ 6 files changed, 4 insertions(+), 22 deletions(-) (limited to 'cocoa') diff --git a/cocoa/BrowserViewController.h b/cocoa/BrowserViewController.h index 020e49e25..4ddfb7f76 100644 --- a/cocoa/BrowserViewController.h +++ b/cocoa/BrowserViewController.h @@ -49,8 +49,6 @@ struct browser_window; - (IBAction) backForwardSelected: (id) sender; -- (IBAction) showHistory: (id) sender; - - (IBAction) goBack: (id) sender; - (IBAction) goForward: (id) sender; - (IBAction) reloadPage: (id) sender; diff --git a/cocoa/DownloadWindowController.m b/cocoa/DownloadWindowController.m index ff28d1e9f..0afbd89fb 100644 --- a/cocoa/DownloadWindowController.m +++ b/cocoa/DownloadWindowController.m @@ -21,8 +21,6 @@ #import "desktop/download.h" #import "desktop/gui.h" -#define UNIMPL() NSLog( @"Function '%s' unimplemented", __func__ ) - @interface DownloadWindowController () @property (readwrite, retain, nonatomic) NSFileHandle *outputFile; diff --git a/cocoa/TreeView.m b/cocoa/TreeView.m index 00fb4808c..467668313 100644 --- a/cocoa/TreeView.m +++ b/cocoa/TreeView.m @@ -22,7 +22,6 @@ #import "desktop/plotters.h" #import "desktop/history_global_core.h" -#define UNIMPL() NSLog( @"Function '%s' unimplemented", __func__ ) @implementation TreeView diff --git a/cocoa/gui.m b/cocoa/gui.m index 83c0cbd65..296d73d31 100644 --- a/cocoa/gui.m +++ b/cocoa/gui.m @@ -345,7 +345,7 @@ static char *gui_get_resource_url( NSString *name, NSString *type ) return strdup( [[[NSURL fileURLWithPath: path] absoluteString] UTF8String] ); } -static NSString *cocoa_get_preferences_path() +static NSString *cocoa_get_preferences_path( void ) { NSArray *paths = NSSearchPathForDirectoriesInDomains( NSApplicationSupportDirectory, NSUserDomainMask, YES ); NSCAssert( [paths count] >= 1, @"Where is the application support directory?" ); @@ -367,7 +367,7 @@ static NSString *cocoa_get_preferences_path() return netsurfPath; } -static const char *cocoa_get_options_file() +static const char *cocoa_get_options_file( void ) { NSString *prefPath = [cocoa_get_preferences_path() stringByAppendingPathComponent: @"options"]; return [prefPath UTF8String]; diff --git a/cocoa/url.m b/cocoa/url.m index 38d637e6e..33c8bfe61 100644 --- a/cocoa/url.m +++ b/cocoa/url.m @@ -22,7 +22,6 @@ #import -#define UNIMPL() NSLog( @"Function '%s' unimplemented", __func__ ) char *url_to_path(const char *url) { @@ -32,6 +31,6 @@ char *url_to_path(const char *url) char *path_to_url(const char *path) { - UNIMPL(); - return NULL; + return strdup( [[[NSURL fileURLWithPath: [NSString stringWithUTF8String: path]] + absoluteString] UTF8String] ); } diff --git a/cocoa/utils.m b/cocoa/utils.m index 0b06b1d9a..2b365878e 100644 --- a/cocoa/utils.m +++ b/cocoa/utils.m @@ -32,18 +32,6 @@ void warn_user(const char *warning, const char *detail) NSRunAlertPanel( @"Warning", @"Warning %s: %s", @"OK", nil, nil, warning, detail ); } -query_id query_user(const char *query, const char *detail, - const query_callback *cb, void *pw, const char *yes, const char *no) -{ - UNIMPL(); - return 0; -} - -void query_close(query_id qid) -{ - UNIMPL(); -} - void PDF_Password(char **owner_pass, char **user_pass, char *path) { UNIMPL(); -- cgit v1.2.3