summaryrefslogtreecommitdiff
path: root/cocoa
diff options
context:
space:
mode:
Diffstat (limited to 'cocoa')
-rw-r--r--cocoa/NetsurfApp.m4
-rw-r--r--cocoa/bitmap.h4
-rw-r--r--cocoa/bitmap.m16
3 files changed, 22 insertions, 2 deletions
diff --git a/cocoa/NetsurfApp.m b/cocoa/NetsurfApp.m
index d76aee10c..ac26c9cf4 100644
--- a/cocoa/NetsurfApp.m
+++ b/cocoa/NetsurfApp.m
@@ -24,6 +24,7 @@
#import "cocoa/SearchWindowController.h"
#import "cocoa/selection.h"
#import "cocoa/fetch.h"
+#import "cocoa/bitmap.h"
#import "utils/filename.h"
#import "utils/log.h"
@@ -220,7 +221,8 @@ int main( int argc, char **argv )
.clipboard = cocoa_clipboard_table,
.download = cocoa_download_table,
.fetch = cocoa_fetch_table,
- .search = cocoa_search_table,
+ .search = cocoa_search_table,
+ .bitmap = cocoa_bitmap_table,
};
cocoa_autorelease();
diff --git a/cocoa/bitmap.h b/cocoa/bitmap.h
index 78526e425..dc463b8f5 100644
--- a/cocoa/bitmap.h
+++ b/cocoa/bitmap.h
@@ -21,4 +21,6 @@
CGImageRef cocoa_get_cgimage( void *bitmap );
-#endif \ No newline at end of file
+struct gui_bitmap_table *cocoa_bitmap_table;
+
+#endif
diff --git a/cocoa/bitmap.m b/cocoa/bitmap.m
index 45b1d3b19..45ea1e0a2 100644
--- a/cocoa/bitmap.m
+++ b/cocoa/bitmap.m
@@ -215,3 +215,19 @@ static CGImageRef cocoa_prepare_bitmap( void *bitmap )
return result;
}
+static struct gui_bitmap_table bitmap_table = {
+ .create = bitmap_create,
+ .destroy = bitmap_destroy,
+ .set_opaque = bitmap_set_opaque,
+ .get_opaque = bitmap_get_opaque,
+ .test_opaque = bitmap_test_opaque,
+ .get_buffer = bitmap_get_buffer,
+ .get_rowstride = bitmap_get_rowstride,
+ .get_width = bitmap_get_width,
+ .get_height = bitmap_get_height,
+ .get_bpp = bitmap_get_bpp,
+ .save = bitmap_save,
+ .modified = bitmap_modified,
+};
+
+struct gui_bitmap_table *cocoa_bitmap_table = &bitmap_table;