Author: post
Date: 2011-01-14 12:21:44 +0100 (Fri, 14 Jan 2011)
New Revision: 3799

Modified:
   trunk/src/application.c
   trunk/src/application.h
Log:
Add helper function to easily get the main blob.

Modified: trunk/src/application.c
===================================================================
--- trunk/src/application.c     2011-01-14 10:39:23 UTC (rev 3798)
+++ trunk/src/application.c     2011-01-14 11:21:44 UTC (rev 3799)
@@ -694,6 +694,13 @@
 
 #endif  // defined(RS_USE_INTERNAL_STACKTRACE)
 
+static RS_BLOB* main_blob = NULL;
+
+RS_BLOB* rs_get_blob()
+{
+       return main_blob;
+}
+
 int
 main(int argc, char **argv)
 {
@@ -762,7 +769,7 @@
        gconf_client_add_dir(client, "/apps/" PACKAGE, 
GCONF_CLIENT_PRELOAD_NONE, NULL);
 #endif
 
-       rs = rs_new();
+       rs = main_blob = rs_new();
 
        rs_stock_init();
        rs_lens_fix_init();
@@ -771,7 +778,7 @@
        gtk_link_button_set_uri_hook(runuri,NULL,NULL);
 #endif
 
-//     g_log_set_always_fatal(G_LOG_LEVEL_CRITICAL | G_LOG_LEVEL_ERROR | 
G_LOG_LEVEL_WARNING);
+//     g_log_set_always_fatal(G_LOG_LEVEL_CRITICAL | G_LOG_LEVEL_ERROR);
        if (do_test)
                test();
        else

Modified: trunk/src/application.h
===================================================================
--- trunk/src/application.h     2011-01-14 10:39:23 UTC (rev 3798)
+++ trunk/src/application.h     2011-01-14 11:21:44 UTC (rev 3799)
@@ -90,6 +90,8 @@
 gboolean rs_photo_copy_to_clipboard(RS_PHOTO *photo, RSFilter 
*prior_to_resample, gint width, gint height, gboolean keep_aspect, gdouble 
scale, gint snapshot);
 RS_BLOB *rs_new();
 void rs_free(RS_BLOB *rs);
+/* Cheater function to get the main blob - use carefully! */
+RS_BLOB* rs_get_blob();
 void rs_set_photo(RS_BLOB *rs, RS_PHOTO *photo);
 void rs_white_black_point(RS_BLOB *rs);
 


_______________________________________________
Rawstudio-commit mailing list
[email protected]
http://rawstudio.org/cgi-bin/mailman/listinfo/rawstudio-commit

Reply via email to