glom r1666 - in trunk: . glom/utility_widgets win32
- From: arminb svn gnome org
- To: svn-commits-list gnome org
- Subject: glom r1666 - in trunk: . glom/utility_widgets win32
- Date: Sat, 23 Aug 2008 10:27:23 +0000 (UTC)
Author: arminb
Date: Sat Aug 23 10:27:23 2008
New Revision: 1666
URL: http://svn.gnome.org/viewvc/glom?rev=1666&view=rev
Log:
2008-08-23 Armin Burgmeier <armin openismus com>
* glom/utility_widgets/layouttoolbar.cc: Locate images relative to
application executable on Windows.
* win32/build_installer:
* win32/glom.iss.in: Added pixmaps to the installer.
Modified:
trunk/ChangeLog
trunk/glom/utility_widgets/layouttoolbar.cc
trunk/win32/build-installer
trunk/win32/glom.iss.in
Modified: trunk/glom/utility_widgets/layouttoolbar.cc
==============================================================================
--- trunk/glom/utility_widgets/layouttoolbar.cc (original)
+++ trunk/glom/utility_widgets/layouttoolbar.cc Sat Aug 23 10:27:23 2008
@@ -27,6 +27,21 @@
#include "layoutwidgetbase.h"
#include "egg/toolpalette/eggtoolitemgroup.h"
+namespace
+{
+ Glib::ustring get_icon_path(const Glib::ustring& filename)
+ {
+#ifdef G_OS_WIN32
+ gchar* basepath = g_win32_get_package_installation_subdirectory(NULL, NULL, "share/glom/pixmaps");
+ Glib::ustring result = Glib::build_filename(basepath, filename);
+ g_free(basepath);
+ return result;
+#else
+ return Glib::build_filename(GLOM_ICON_DIR, filename);
+#endif
+ }
+}
+
namespace Glom
{
@@ -36,19 +51,18 @@
set_size_request(100, 200);
Gtk::Image* image_item =
- Gtk::manage (new Gtk::Image(GLOM_ICON_DIR "/glom-field.png"));
+ Gtk::manage (new Gtk::Image(get_icon_path("glom-field.png")));
Gtk::Image* image_button =
- Gtk::manage (new Gtk::Image(GLOM_ICON_DIR "/glom-button.png"));
+ Gtk::manage (new Gtk::Image(get_icon_path("glom-button.png")));
Gtk::Image* image_text =
- Gtk::manage (new Gtk::Image(GLOM_ICON_DIR "/glom-text.png"));
+ Gtk::manage (new Gtk::Image(get_icon_path("glom-text.png")));
Gtk::Image* image_image =
- Gtk::manage (new Gtk::Image(GLOM_ICON_DIR "/glom-image.png"));
+ Gtk::manage (new Gtk::Image(get_icon_path("glom-image.png")));
Gtk::Image* image_group =
- Gtk::manage (new Gtk::Image(GLOM_ICON_DIR "/glom-group.png"));
+ Gtk::manage (new Gtk::Image(get_icon_path("glom-group.png")));
Gtk::Image* image_notebook =
- Gtk::manage (new Gtk::Image(GLOM_ICON_DIR "/glom-notebook.png"));
-
+ Gtk::manage (new Gtk::Image(get_icon_path("glom-notebook.png")));
LayoutToolbarButton* drag_group =
Gtk::manage(new LayoutToolbarButton(*image_group, LayoutWidgetBase::TYPE_GROUP,
Modified: trunk/win32/build-installer
==============================================================================
--- trunk/win32/build-installer (original)
+++ trunk/win32/build-installer Sat Aug 23 10:27:23 2008
@@ -252,9 +252,8 @@
cp /local/share/glom/glade/glom.glade installer/share/glom/glade || exit
cp /local/share/glom/glade/glom_developer.glade installer/share/glom/glade || exit
cp -R /local/share/glom/doc installer/share/glom/ || exit
+cp -R /local/share/glom/pixmaps installer/share/glom/ || exit
-# TODO: /local/share/glom/doc/examples
-# TODO: /local/share/glom/pixmaps (requires correct lookup in glom)
# TODO: /local/share/glom/xslt/* (what is this used for?)
mkdir -p installer/share/icons/hicolor/48x48/apps || exit
Modified: trunk/win32/glom.iss.in
==============================================================================
--- trunk/win32/glom.iss.in (original)
+++ trunk/win32/glom.iss.in Sat Aug 23 10:27:23 2008
@@ -158,6 +158,7 @@
Source: "share/glom/glade/glom.glade"; DestDir: "{app}/share/glom/glade"; Components: main
Source: "share/glom/glade/glom_developer.glade"; DestDir: "{app}/share/glom/glade"; Components: main
Source: "share/glom/doc/*"; Destdir: "{app}/share/glom/doc/"; Components: main; Flags: recursesubdirs
+Source: "share/glom/pixmaps/*"; Destdir: "{app}/share/glom/pixmaps/"; Components: main; Flags: recursesubdirs
;Source: "share/themes/MS-Windows/*"; DestDir: "{app}/share/themes/MS-Windows"; Flags: recursesubdirs; Components: gtk
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]