summaryrefslogtreecommitdiffstats
path: root/src/ui
diff options
context:
space:
mode:
authorJohn Smith <john.smith7545@yahoo.com>2012-08-05 07:26:21 +0000
committerJohn Smith <john.smith7545@yahoo.com>2012-08-05 07:26:21 +0000
commit1ddcf4688a13701d9de2bcf9c970226e9fba2ddd (patch)
tree804360ea8f69372fbf92ce73b74527f84f16bf5c /src/ui
parentExporting. Optimized SVG output extension update (scour). (diff)
downloadinkscape-1ddcf4688a13701d9de2bcf9c970226e9fba2ddd.tar.gz
inkscape-1ddcf4688a13701d9de2bcf9c970226e9fba2ddd.zip
Fix for 484135 : clicking on the stroke size doesn't open the dialog box
(bzr r11592)
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/widget/rotateable.cpp16
-rw-r--r--src/ui/widget/selected-style.cpp1
2 files changed, 9 insertions, 8 deletions
diff --git a/src/ui/widget/rotateable.cpp b/src/ui/widget/rotateable.cpp
index c31e6f529..7be666843 100644
--- a/src/ui/widget/rotateable.cpp
+++ b/src/ui/widget/rotateable.cpp
@@ -33,16 +33,16 @@ Rotateable::Rotateable():
}
bool Rotateable::on_click(GdkEventButton *event) {
- if (event->button == 1) {
+ if (event->button == 1) {
drag_started_x = event->x;
drag_started_y = event->y;
- modifier = get_single_modifier(modifier, event->state);
+ modifier = get_single_modifier(modifier, event->state);
dragging = true;
working = false;
current_axis = axis;
return true;
- }
- return false;
+ }
+ return false;
}
guint Rotateable::get_single_modifier(guint old, guint state) {
@@ -108,9 +108,9 @@ bool Rotateable::on_motion(GdkEventMotion *event) {
bool Rotateable::on_release(GdkEventButton *event) {
- if (dragging && working) {
+ if (dragging && working) {
double angle = atan2(event->y - drag_started_y, event->x - drag_started_x);
- double force = CLAMP (-(angle - current_axis)/maxdecl, -1, 1);
+ double force = CLAMP(-(angle - current_axis) / maxdecl, -1, 1);
if (fabs(force) < 0.002)
force = 0; // snap to zero
do_release(force, modifier);
@@ -118,10 +118,10 @@ bool Rotateable::on_release(GdkEventButton *event) {
dragging = false;
working = false;
return true;
- }
+ }
dragging = false;
working = false;
- return false;
+ return false;
}
diff --git a/src/ui/widget/selected-style.cpp b/src/ui/widget/selected-style.cpp
index 867ec62a9..a37f36eea 100644
--- a/src/ui/widget/selected-style.cpp
+++ b/src/ui/widget/selected-style.cpp
@@ -333,6 +333,7 @@ SelectedStyle::SelectedStyle(bool /*layout*/)
_stroke_place.signal_button_release_event().connect(sigc::mem_fun(*this, &SelectedStyle::on_stroke_click));
_opacity_place.signal_button_press_event().connect(sigc::mem_fun(*this, &SelectedStyle::on_opacity_click));
_stroke_width_place.signal_button_press_event().connect(sigc::mem_fun(*this, &SelectedStyle::on_sw_click));
+ _stroke_width_place.signal_button_release_event().connect(sigc::mem_fun(*this, &SelectedStyle::on_sw_click));
_opacity_sb.signal_populate_popup().connect(sigc::mem_fun(*this, &SelectedStyle::on_opacity_menu));
_opacity_sb.signal_value_changed().connect(sigc::mem_fun(*this, &SelectedStyle::on_opacity_changed));