diff options
| author | Alex Valavanis <valavanisalex@gmail.com> | 2016-12-27 14:38:57 +0000 |
|---|---|---|
| committer | Alexander Valavanis <valavanisalex@gmail.com> | 2016-12-27 14:38:57 +0000 |
| commit | d14c66ec084bb5a53e1a47942cca89f189da8caf (patch) | |
| tree | 3f38a37d0d9220e684366f2c9a8f233bb85991f7 /src/ui/widget | |
| parent | Rm some deprecated Gtk::Stock usage (diff) | |
| download | inkscape-d14c66ec084bb5a53e1a47942cca89f189da8caf.tar.gz inkscape-d14c66ec084bb5a53e1a47942cca89f189da8caf.zip | |
Rm more deprecated Gtk::Stock
(bzr r15367)
Diffstat (limited to 'src/ui/widget')
| -rw-r--r-- | src/ui/widget/dock-item.cpp | 8 | ||||
| -rw-r--r-- | src/ui/widget/preferences-widget.cpp | 6 |
2 files changed, 3 insertions, 11 deletions
diff --git a/src/ui/widget/dock-item.cpp b/src/ui/widget/dock-item.cpp index 2860df12e..d124854ae 100644 --- a/src/ui/widget/dock-item.cpp +++ b/src/ui/widget/dock-item.cpp @@ -15,7 +15,6 @@ #include "widgets/icon.h" #include <gtkmm/icontheme.h> -#include <gtkmm/stockitem.h> #include <glibmm/exceptionhandler.h> namespace Inkscape { @@ -47,18 +46,11 @@ DockItem::DockItem(Dock& dock, const Glib::ustring& name, const Glib::ustring& l if (!iconTheme->has_icon(icon_name)) { Inkscape::queueIconPrerender( INKSCAPE_ICON(icon_name.data()), Inkscape::ICON_SIZE_MENU ); } - // Icon might be in the icon theme, or might be a stock item. Check the proper source: if ( iconTheme->has_icon(icon_name) ) { int width = 0; int height = 0; Gtk::IconSize::lookup(Gtk::ICON_SIZE_MENU, width, height); _icon_pixbuf = iconTheme->load_icon(icon_name, width); - } else { - Gtk::StockItem item; - Gtk::StockID stockId(icon_name); - if ( Gtk::StockItem::lookup(stockId, item) ) { - _icon_pixbuf = _dock.getWidget().render_icon_pixbuf( stockId, Gtk::ICON_SIZE_MENU ); - } } } diff --git a/src/ui/widget/preferences-widget.cpp b/src/ui/widget/preferences-widget.cpp index 1205cd012..b2cebcaa6 100644 --- a/src/ui/widget/preferences-widget.cpp +++ b/src/ui/widget/preferences-widget.cpp @@ -18,7 +18,6 @@ #include <gtkmm/frame.h> #include <gtkmm/alignment.h> #include <gtkmm/scale.h> -#include <gtkmm/stock.h> #include <gtkmm/table.h> #include "preferences.h" @@ -708,8 +707,9 @@ void PrefEntryFileButtonHBox::init(Glib::ustring const &prefs_path, relatedButton = new Gtk::Button(); Gtk::HBox* pixlabel = new Gtk::HBox(false, 3); - Gtk::Image *im = new Gtk::Image(Gtk::StockID(Gtk::Stock::INDEX), - Gtk::ICON_SIZE_BUTTON); + Gtk::Image *im = new Gtk::Image(); + im->set_from_icon_name("applications-graphics", + Gtk::ICON_SIZE_BUTTON); pixlabel->pack_start(*im); Gtk::Label *l = new Gtk::Label(); l->set_markup_with_mnemonic(_("_Browse...")); |
