summaryrefslogtreecommitdiff
path: root/src/editing_tools/EditingTools.vala
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff.email>2018-09-30 14:09:32 +0200
committerJörg Frings-Fürst <debian@jff.email>2018-09-30 14:09:32 +0200
commit0537caaf4af94a9ead8b292679f6b34c90b55e06 (patch)
tree6761cfdf959926be7af3147cf770e7f253390fe8 /src/editing_tools/EditingTools.vala
parenteca5837e235a356c8db9416bbbc13577db3e6f76 (diff)
parent5e9f4eea451a77ba3b93db3747841ed2bd969e9f (diff)
Update upstream source from tag 'upstream/0.30.1'
Update to upstream version '0.30.1' with Debian dir dc242531effff8d9c6fab093414edee28b403c6a
Diffstat (limited to 'src/editing_tools/EditingTools.vala')
-rw-r--r--src/editing_tools/EditingTools.vala20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/editing_tools/EditingTools.vala b/src/editing_tools/EditingTools.vala
index ee08f84..f92b4a2 100644
--- a/src/editing_tools/EditingTools.vala
+++ b/src/editing_tools/EditingTools.vala
@@ -654,7 +654,7 @@ public class CropTool : EditingTool {
constraint_combo.set_row_separator_func(constraint_combo_separator_func);
constraint_combo.set_active(0);
- var image = new Gtk.Image.from_icon_name("crop-pivot-reticle", Gtk.IconSize.LARGE_TOOLBAR);
+ var image = new Gtk.Image.from_icon_name("crop-pivot-reticle-symbolic", Gtk.IconSize.LARGE_TOOLBAR);
pivot_reticle_button.set_image (image);
pivot_reticle_button.set_tooltip_text(_("Pivot the crop rectangle between portrait and landscape orientations"));
@@ -786,9 +786,9 @@ public class CropTool : EditingTool {
result.basis_width = canvas.get_scaled_pixbuf_position().width;
result.basis_height = canvas.get_scaled_pixbuf_position().height;
} else if (result.aspect_ratio == SCREEN_ASPECT_RATIO) {
- Gdk.Screen screen = Gdk.Screen.get_default();
- result.basis_width = screen.get_width();
- result.basis_height = screen.get_height();
+ var dim = Scaling.get_screen_dimensions(AppWindow.get_instance());
+ result.basis_width = dim.width;
+ result.basis_height = dim.height;
}
return result;
@@ -890,14 +890,14 @@ public class CropTool : EditingTool {
}
private float get_constraint_aspect_ratio() {
- float result = get_selected_constraint().aspect_ratio;
+ var result = get_selected_constraint().aspect_ratio;
if (result == ORIGINAL_ASPECT_RATIO) {
result = ((float) canvas.get_scaled_pixbuf_position().width) /
((float) canvas.get_scaled_pixbuf_position().height);
} else if (result == SCREEN_ASPECT_RATIO) {
- Gdk.Screen screen = Gdk.Screen.get_default();
- result = ((float) screen.get_width()) / ((float) screen.get_height());
+ var dim = Scaling.get_screen_dimensions(AppWindow.get_instance());
+ result = ((float) dim.width) / ((float) dim.height);
} else if (result == CUSTOM_ASPECT_RATIO) {
result = custom_aspect_ratio;
}
@@ -914,8 +914,8 @@ public class CropTool : EditingTool {
Dimensions orig_dim = photo.get_original_dimensions();
result = ((float) orig_dim.width) / ((float) orig_dim.height);
} else if (result == SCREEN_ASPECT_RATIO) {
- Gdk.Screen screen = Gdk.Screen.get_default();
- result = ((float) screen.get_width()) / ((float) screen.get_height());
+ var dim = Scaling.get_screen_dimensions(AppWindow.get_instance());
+ result = ((float) dim.width) / ((float) dim.height);
} else if (result == CUSTOM_ASPECT_RATIO) {
result = custom_aspect_ratio;
}
@@ -2251,7 +2251,7 @@ public class AdjustTool : EditingTool {
slider_organizer.attach(saturation_label, 0, 2, 1, 1);
slider_organizer.attach(saturation_slider, 1, 2, 1, 1);
saturation_slider.set_size_request(SLIDER_WIDTH, -1);
- saturation_slider.set_value_pos(Gtk.PositionType.RIGHT);
+ saturation_slider.set_draw_value(false);
saturation_slider.set_margin_end(0);
Gtk.Label tint_label = new Gtk.Label.with_mnemonic(_("Tint:"));