[chronojump] Fixed: 652058 - Hide SQL query.Also Fixed decimals
- From: Xavier de Blas <xaviblas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [chronojump] Fixed: 652058 - Hide SQL query.Also Fixed decimals
- Date: Tue, 8 Jan 2013 01:11:33 +0000 (UTC)
commit 46e7baa609fc31dcaa78f314cb57f819bce9aa1b
Author: Xavier de Blas <xaviblas gmail com>
Date: Tue Jan 8 01:57:57 2013 +0100
Fixed: 652058 - Hide SQL query.Also Fixed decimals
glade/chronojump.glade | 53 ++++++++++++++++++++++++++++++++++++-----------
src/gui/queryServer.cs | 12 ++++++++++-
2 files changed, 51 insertions(+), 14 deletions(-)
---
diff --git a/glade/chronojump.glade b/glade/chronojump.glade
index a846e54..c1b1e56 100644
--- a/glade/chronojump.glade
+++ b/glade/chronojump.glade
@@ -25304,22 +25304,49 @@ show elevation as:</property>
<property name="can_focus">False</property>
<property name="spacing">8</property>
<child>
- <widget class="GtkScrolledWindow" id="scrolledwindow37">
- <property name="height_request">36</property>
+ <widget class="GtkVBox" id="vbox1">
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="hscrollbar_policy">never</property>
- <property name="vscrollbar_policy">automatic</property>
- <property name="shadow_type">in</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">2</property>
<child>
- <widget class="GtkTextView" id="textview_query">
+ <widget class="GtkCheckButton" id="check_show_query">
+ <property name="label" translatable="yes">Show query</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="editable">False</property>
- <property name="wrap_mode">word</property>
- <property name="cursor_visible">False</property>
- <property name="accepts_tab">False</property>
+ <property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
+ <property name="draw_indicator">True</property>
+ <signal name="toggled" handler="on_check_show_query_toggled" swapped="no"/>
</widget>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <widget class="GtkScrolledWindow" id="scrolledwindow_query">
+ <property name="height_request">36</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">never</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <widget class="GtkTextView" id="textview_query">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="wrap_mode">word</property>
+ <property name="cursor_visible">False</property>
+ <property name="accepts_tab">False</property>
+ </widget>
+ </child>
+ </widget>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
</child>
</widget>
<packing>
@@ -25460,10 +25487,10 @@ show elevation as:</property>
</widget>
</child>
<child>
- <widget class="GtkLabel" id="label757">
+ <widget class="GtkLabel" id="label1">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">Execute query</property>
+ <property name="label" translatable="yes">Query</property>
<attributes>
<attribute name="weight" value="bold"/>
</attributes>
diff --git a/src/gui/queryServer.cs b/src/gui/queryServer.cs
index 04e1328..2c55111 100644
--- a/src/gui/queryServer.cs
+++ b/src/gui/queryServer.cs
@@ -62,6 +62,10 @@ public class QueryServerWindow
[Widget] Gtk.SpinButton spin_ages1;
[Widget] Gtk.SpinButton spin_ages2;
[Widget] Gtk.Label label_speciallity;
+
+ [Widget] Gtk.CheckButton check_show_query;
+ [Widget] Gtk.ScrolledWindow scrolledwindow_query;
+
[Widget] Gtk.Label label_results_num;
[Widget] Gtk.Label label_results_avg;
[Widget] Gtk.Label label_results_num_units;
@@ -752,7 +756,7 @@ public class QueryServerWindow
label_results_avg.Text = "-";
else
label_results_avg.Text = Util.TrimDecimals(
- Util.ConvertToPointIfNeeded(resultFull[1]), pDN);
+ Util.ChangeDecimalSeparator(resultFull[1]), pDN);
}
return sqlString;
@@ -797,6 +801,12 @@ public class QueryServerWindow
on_entries_required_changed(new object(), new EventArgs());
}
+ private void on_check_show_query_toggled(object o, EventArgs args)
+ {
+ scrolledwindow_query.Visible = check_show_query.Active;
+ }
+
+
protected void on_button_search_clicked (object o, EventArgs args)
{
sqlBuildSelect(true);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]