summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Valavanis <valavanisalex@gmail.com>2012-10-13 23:12:23 +0000
committerAlex Valavanis <valavanisalex@gmail.com>2012-10-13 23:12:23 +0000
commit162b892e2dd76ff4a028b9f0239eb6d8b1aa9452 (patch)
tree406287a2dbd344842b8071ec9e3b40d1eca8322b
parentShift key should disable snapping when dragging a handle in the node tool (diff)
downloadinkscape-162b892e2dd76ff4a028b9f0239eb6d8b1aa9452.tar.gz
inkscape-162b892e2dd76ff4a028b9f0239eb6d8b1aa9452.zip
GTK+ 3: Fix crash with live-preview checkbox in extensions dialog
Fixed bugs: - https://launchpad.net/bugs/1012741 (bzr r11792)
-rw-r--r--share/extensions/gears.inx2
-rw-r--r--src/extension/prefdialog.cpp10
2 files changed, 5 insertions, 7 deletions
diff --git a/share/extensions/gears.inx b/share/extensions/gears.inx
index f5bc23550..78d556b4a 100644
--- a/share/extensions/gears.inx
+++ b/share/extensions/gears.inx
@@ -13,7 +13,7 @@
<_option value="in">in</_option>
<_option value="mm">mm</_option>
</param>
- <_param name="unit_text" type="description">Unit of measure for both circular pitch and center diameter.</_param>
+ <_param name="unit_text" type="description">Unit of measurement for both circular pitch and center diameter.</_param>
<effect>
<object-type>all</object-type>
<effects-menu>
diff --git a/src/extension/prefdialog.cpp b/src/extension/prefdialog.cpp
index 94f128a42..2d2604c7f 100644
--- a/src/extension/prefdialog.cpp
+++ b/src/extension/prefdialog.cpp
@@ -32,13 +32,13 @@ namespace Extension {
/** \brief Creates a new preference dialog for extension preferences
- \param name Name of the Extension who's dialog this is
+ \param name Name of the Extension whose dialog this is
\param help The help string for the extension (NULL if none)
\param controls The extension specific widgets in the dialog
This function initializes the dialog with the name of the extension
in the title. It adds a few buttons and sets up handlers for
- them. It also places the passed in widgets into the dialog.
+ them. It also places the passed-in widgets into the dialog.
*/
PrefDialog::PrefDialog (Glib::ustring name, gchar const * help, Gtk::Widget * controls, Effect * effect) :
#if WITH_GTKMM_3_0
@@ -102,12 +102,10 @@ PrefDialog::PrefDialog (Glib::ustring name, gchar const * help, Gtk::Widget * co
Gtk::Box * hbox = dynamic_cast<Gtk::Box *>(_button_preview);
if (hbox != NULL) {
#if WITH_GTKMM_3_0
- Gtk::Widget * back = hbox->get_children().back();
+ _checkbox_preview = dynamic_cast<Gtk::CheckButton *>(hbox->get_children().front());
#else
- Gtk::Widget * back = hbox->children().back().get_widget();
+ _checkbox_preview = dynamic_cast<Gtk::CheckButton *>(hbox->children().back().get_widget());
#endif
- Gtk::CheckButton * cb = dynamic_cast<Gtk::CheckButton *>(back);
- _checkbox_preview = cb;
}
preview_toggle();