[latexila] BuildToolsPreferences: _view_ properties for the default build tools
- From: Sébastien Wilmet <swilmet src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [latexila] BuildToolsPreferences: _view_ properties for the default build tools
- Date: Mon, 6 Apr 2015 15:12:10 +0000 (UTC)
commit 3b96b8d9981202ab00884ad1977a3bb9690d75a1
Author: Sébastien Wilmet <swilmet gnome org>
Date: Mon Apr 6 16:13:55 2015 +0200
BuildToolsPreferences: _view_ properties for the default build tools
Since the default build tools are read-only. Change also the icon.
src/build_tools_preferences.vala | 21 +++++++++++++++------
1 files changed, 15 insertions(+), 6 deletions(-)
---
diff --git a/src/build_tools_preferences.vala b/src/build_tools_preferences.vala
index 4cc58f0..4568b8f 100644
--- a/src/build_tools_preferences.vala
+++ b/src/build_tools_preferences.vala
@@ -1,7 +1,7 @@
/*
* This file is part of LaTeXila.
*
- * Copyright © 2012, 2014 Sébastien Wilmet
+ * Copyright © 2012-2015 Sébastien Wilmet
*
* LaTeXila is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -99,7 +99,7 @@ public class BuildToolsPreferences : GLib.Object
Latexila.BuildTools default_build_tools =
Latexila.BuildToolsDefault.get_instance () as Latexila.BuildTools;
ToolButton properties_button = get_properties_button (_default_view,
- default_build_tools);
+ default_build_tools, true);
ToolButton copy_button = get_copy_button (_default_view, default_build_tools);
Toolbar toolbar = new Toolbar ();
@@ -116,7 +116,7 @@ public class BuildToolsPreferences : GLib.Object
Latexila.BuildTools personal_build_tools =
Latexila.BuildToolsPersonal.get_instance () as Latexila.BuildTools;
ToolButton properties_button = get_properties_button (_personal_view,
- personal_build_tools);
+ personal_build_tools, false);
ToolButton copy_button = get_copy_button (_personal_view, personal_build_tools);
Toolbar toolbar = new Toolbar ();
@@ -237,11 +237,20 @@ public class BuildToolsPreferences : GLib.Object
}
private ToolButton get_properties_button (TreeView view,
- Latexila.BuildTools build_tools)
+ Latexila.BuildTools build_tools, bool read_only)
{
ToolButton properties_button = new ToolButton (null, null);
- properties_button.set_icon_name ("document-properties-symbolic");
- properties_button.set_tooltip_text ("Edit the properties");
+
+ if (read_only)
+ {
+ properties_button.set_icon_name ("edit-find-symbolic");
+ properties_button.set_tooltip_text (_("View the properties (read-only)"));
+ }
+ else
+ {
+ properties_button.set_icon_name ("document-properties-symbolic");
+ properties_button.set_tooltip_text (_("Edit the properties"));
+ }
set_sensitivity_on_selection (view, properties_button);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]