[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [vidalia/alpha] Make the new Message Log UI integrate better with the rest of the dialog
commit 86f09729bfafe3b1945d56dd4110f1ee56a44144
Author: Tomás Touceda <chiiph@xxxxxxxxxxxxxx>
Date: Sat Mar 24 12:55:44 2012 -0300
Make the new Message Log UI integrate better with the rest of the dialog
Also disable the search line edit explicitly at load
---
src/vidalia/log/MessageLog.cpp | 2 +
src/vidalia/log/MessageLog.ui | 388 +++++++++++++++++++++++++---------------
2 files changed, 244 insertions(+), 146 deletions(-)
diff --git a/src/vidalia/log/MessageLog.cpp b/src/vidalia/log/MessageLog.cpp
index f4bfe07..e352d86 100644
--- a/src/vidalia/log/MessageLog.cpp
+++ b/src/vidalia/log/MessageLog.cpp
@@ -217,6 +217,8 @@ MessageLog::loadSettings()
const QString term = getSetting(SETTING_FILTER_TERM, DEFAULT_FILTER_TERM)
.toString();
ui.chkFilterSearch->setChecked(!term.isEmpty());
+ ui.lineSearchTerm->setEnabled(!term.isEmpty());
+
ui.lineSearchTerm->setText(term);
buildMessageFilter(term);
diff --git a/src/vidalia/log/MessageLog.ui b/src/vidalia/log/MessageLog.ui
index 029e933..7b8e05a 100644
--- a/src/vidalia/log/MessageLog.ui
+++ b/src/vidalia/log/MessageLog.ui
@@ -6,17 +6,20 @@
<rect>
<x>0</x>
<y>0</y>
- <width>540</width>
- <height>521</height>
+ <width>671</width>
+ <height>626</height>
</rect>
</property>
<property name="windowTitle">
<string notr="true"/>
</property>
- <layout class="QVBoxLayout" name="verticalLayout_2">
- <item>
- <layout class="QVBoxLayout" name="verticalLayout">
- <item>
+ <layout class="QGridLayout" name="gridLayout_2">
+ <item row="1" column="2">
+ <layout class="QGridLayout" name="gridLayout_3">
+ <property name="horizontalSpacing">
+ <number>0</number>
+ </property>
+ <item row="0" column="1">
<widget class="LogTreeWidget" name="listMessages">
<property name="contextMenuPolicy">
<enum>Qt::NoContextMenu</enum>
@@ -59,13 +62,13 @@
</column>
</widget>
</item>
- <item>
+ <item row="1" column="1">
<widget class="QFrame" name="frmSettings">
<property name="enabled">
<bool>true</bool>
</property>
<property name="sizePolicy">
- <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
+ <sizepolicy hsizetype="Minimum" vsizetype="Minimum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
@@ -73,13 +76,13 @@
<property name="minimumSize">
<size>
<width>520</width>
- <height>183</height>
+ <height>261</height>
</size>
</property>
<property name="maximumSize">
<size>
- <width>520</width>
- <height>183</height>
+ <width>800</width>
+ <height>261</height>
</size>
</property>
<property name="contextMenuPolicy">
@@ -101,107 +104,91 @@
<property name="spacing">
<number>3</number>
</property>
- <item row="0" column="2">
- <layout class="QHBoxLayout" name="_2">
- <item>
- <spacer>
- <property name="orientation">
- <enum>Qt::Horizontal</enum>
- </property>
- <property name="sizeHint" stdset="0">
- <size>
- <width>40</width>
- <height>20</height>
- </size>
- </property>
- </spacer>
- </item>
- <item>
- <layout class="QVBoxLayout" name="_3">
- <item>
- <widget class="QPushButton" name="btnSaveSettings">
- <property name="contextMenuPolicy">
- <enum>Qt::NoContextMenu</enum>
- </property>
- <property name="toolTip">
- <string>Saves the current Message Log settings</string>
- </property>
- <property name="text">
- <string>Save Settings</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QPushButton" name="btnCancelSettings">
- <property name="minimumSize">
- <size>
- <width>90</width>
- <height>0</height>
- </size>
- </property>
- <property name="contextMenuPolicy">
- <enum>Qt::NoContextMenu</enum>
- </property>
- <property name="toolTip">
- <string>Cancels changes made to settings</string>
- </property>
- <property name="text">
- <string>Cancel</string>
- </property>
- </widget>
- </item>
- </layout>
- </item>
- </layout>
- </item>
- <item row="0" column="0" rowspan="2">
- <widget class="QGroupBox" name="grpLogFilter">
+ <item row="1" column="1">
+ <widget class="QGroupBox" name="grpLogHistory">
<property name="contextMenuPolicy">
<enum>Qt::NoContextMenu</enum>
</property>
<property name="title">
- <string>Message Filter</string>
+ <string>Message Log History</string>
</property>
- <layout class="QVBoxLayout" name="_4">
+ <layout class="QHBoxLayout" name="_5">
<item>
- <widget class="QCheckBox" name="chkTorErr">
+ <widget class="QSpinBox" name="spnbxMaxCount">
+ <property name="minimumSize">
+ <size>
+ <width>50</width>
+ <height>0</height>
+ </size>
+ </property>
<property name="contextMenuPolicy">
<enum>Qt::NoContextMenu</enum>
</property>
<property name="toolTip">
- <string/>
+ <string>Number of messages to display in the message log window</string>
</property>
- <property name="whatsThis">
- <string/>
+ <property name="alignment">
+ <set>Qt::AlignRight</set>
</property>
- <property name="text">
- <string>Error</string>
+ <property name="minimum">
+ <number>1</number>
</property>
- <property name="icon">
- <iconset resource="../res/vidalia.qrc">
- <normaloff>:/images/16x16/emblem-important.png</normaloff>:/images/16x16/emblem-important.png</iconset>
+ <property name="maximum">
+ <number>99999</number>
</property>
</widget>
</item>
<item>
- <widget class="QCheckBox" name="chkTorWarn">
+ <widget class="QLabel" name="lblMessageCount">
<property name="contextMenuPolicy">
<enum>Qt::NoContextMenu</enum>
</property>
- <property name="toolTip">
- <string/>
- </property>
<property name="text">
- <string>Warning</string>
+ <string>messages</string>
</property>
- <property name="icon">
- <iconset resource="../res/vidalia.qrc">
- <normaloff>:/images/16x16/dialog-warning.png</normaloff>:/images/16x16/dialog-warning.png</iconset>
+ <property name="textFormat">
+ <enum>Qt::AutoText</enum>
+ </property>
+ <property name="alignment">
+ <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
</property>
</widget>
</item>
- <item>
- <widget class="QCheckBox" name="chkTorNote">
+ </layout>
+ </widget>
+ </item>
+ <item row="0" column="1" colspan="2">
+ <widget class="QGroupBox" name="grpLogFilter">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="minimumSize">
+ <size>
+ <width>0</width>
+ <height>170</height>
+ </size>
+ </property>
+ <property name="contextMenuPolicy">
+ <enum>Qt::NoContextMenu</enum>
+ </property>
+ <property name="title">
+ <string>Message Filter</string>
+ </property>
+ <layout class="QGridLayout" name="_2">
+ <property name="sizeConstraint">
+ <enum>QLayout::SetDefaultConstraint</enum>
+ </property>
+ <item row="8" column="3">
+ <widget class="QCheckBox" name="chkTorInfo">
+ <property name="minimumSize">
+ <size>
+ <width>87</width>
+ <height>20</height>
+ </size>
+ </property>
<property name="contextMenuPolicy">
<enum>Qt::NoContextMenu</enum>
</property>
@@ -209,33 +196,48 @@
<string/>
</property>
<property name="text">
- <string>Notice</string>
+ <string>Info</string>
</property>
<property name="icon">
<iconset resource="../res/vidalia.qrc">
- <normaloff>:/images/16x16/preferences-desktop-notification.png</normaloff>:/images/16x16/preferences-desktop-notification.png</iconset>
+ <normaloff>:/images/16x16/dialog-information.png</normaloff>:/images/16x16/dialog-information.png</iconset>
</property>
</widget>
</item>
- <item>
- <widget class="QCheckBox" name="chkTorInfo">
+ <item row="6" column="1" colspan="2">
+ <widget class="QCheckBox" name="chkTorErr">
+ <property name="minimumSize">
+ <size>
+ <width>124</width>
+ <height>20</height>
+ </size>
+ </property>
<property name="contextMenuPolicy">
<enum>Qt::NoContextMenu</enum>
</property>
<property name="toolTip">
<string/>
</property>
+ <property name="whatsThis">
+ <string/>
+ </property>
<property name="text">
- <string>Info</string>
+ <string>Error</string>
</property>
<property name="icon">
<iconset resource="../res/vidalia.qrc">
- <normaloff>:/images/16x16/dialog-information.png</normaloff>:/images/16x16/dialog-information.png</iconset>
+ <normaloff>:/images/16x16/emblem-important.png</normaloff>:/images/16x16/emblem-important.png</iconset>
</property>
</widget>
</item>
- <item>
+ <item row="6" column="3">
<widget class="QCheckBox" name="chkTorDebug">
+ <property name="minimumSize">
+ <size>
+ <width>87</width>
+ <height>20</height>
+ </size>
+ </property>
<property name="contextMenuPolicy">
<enum>Qt::NoContextMenu</enum>
</property>
@@ -251,84 +253,146 @@
</property>
</widget>
</item>
- <item>
- <layout class="QHBoxLayout" name="horizontalLayout">
- <item>
- <widget class="QCheckBox" name="chkFilterSearch">
- <property name="text">
- <string/>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QLineEdit" name="lineSearchTerm">
- <property name="sizePolicy">
- <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
- <horstretch>0</horstretch>
- <verstretch>0</verstretch>
- </sizepolicy>
- </property>
- </widget>
- </item>
- </layout>
+ <item row="2" column="1" colspan="5">
+ <widget class="QLineEdit" name="lineSearchTerm">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="minimumSize">
+ <size>
+ <width>590</width>
+ <height>22</height>
+ </size>
+ </property>
+ </widget>
</item>
- </layout>
- </widget>
- </item>
- <item row="0" column="1">
- <widget class="QGroupBox" name="grpLogHistory">
- <property name="contextMenuPolicy">
- <enum>Qt::NoContextMenu</enum>
- </property>
- <property name="title">
- <string>Message Log History</string>
- </property>
- <layout class="QHBoxLayout" name="_5">
- <item>
- <widget class="QSpinBox" name="spnbxMaxCount">
+ <item row="7" column="3">
+ <widget class="QCheckBox" name="chkTorNote">
<property name="minimumSize">
<size>
- <width>50</width>
- <height>0</height>
+ <width>87</width>
+ <height>20</height>
</size>
</property>
<property name="contextMenuPolicy">
<enum>Qt::NoContextMenu</enum>
</property>
<property name="toolTip">
- <string>Number of messages to display in the message log window</string>
- </property>
- <property name="alignment">
- <set>Qt::AlignRight</set>
+ <string/>
</property>
- <property name="minimum">
- <number>1</number>
+ <property name="text">
+ <string>Notice</string>
</property>
- <property name="maximum">
- <number>99999</number>
+ <property name="icon">
+ <iconset resource="../res/vidalia.qrc">
+ <normaloff>:/images/16x16/preferences-desktop-notification.png</normaloff>:/images/16x16/preferences-desktop-notification.png</iconset>
</property>
</widget>
</item>
- <item>
- <widget class="QLabel" name="lblMessageCount">
+ <item row="7" column="1" colspan="2">
+ <widget class="QCheckBox" name="chkTorWarn">
+ <property name="minimumSize">
+ <size>
+ <width>124</width>
+ <height>20</height>
+ </size>
+ </property>
<property name="contextMenuPolicy">
<enum>Qt::NoContextMenu</enum>
</property>
+ <property name="toolTip">
+ <string/>
+ </property>
<property name="text">
- <string>messages</string>
+ <string>Warning</string>
</property>
- <property name="textFormat">
- <enum>Qt::AutoText</enum>
+ <property name="icon">
+ <iconset resource="../res/vidalia.qrc">
+ <normaloff>:/images/16x16/dialog-warning.png</normaloff>:/images/16x16/dialog-warning.png</iconset>
</property>
- <property name="alignment">
- <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
+ </widget>
+ </item>
+ <item row="1" column="1">
+ <widget class="QCheckBox" name="chkFilterSearch">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="Minimum">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="minimumSize">
+ <size>
+ <width>114</width>
+ <height>20</height>
+ </size>
+ </property>
+ <property name="text">
+ <string>Filter by term:</string>
</property>
</widget>
</item>
+ <item row="7" column="4">
+ <spacer name="horizontalSpacer">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>1</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item row="6" column="5" rowspan="3">
+ <layout class="QVBoxLayout" name="_3">
+ <item>
+ <widget class="QPushButton" name="btnSaveSettings">
+ <property name="minimumSize">
+ <size>
+ <width>125</width>
+ <height>32</height>
+ </size>
+ </property>
+ <property name="contextMenuPolicy">
+ <enum>Qt::NoContextMenu</enum>
+ </property>
+ <property name="toolTip">
+ <string>Saves the current Message Log settings</string>
+ </property>
+ <property name="text">
+ <string>Save Settings</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QPushButton" name="btnCancelSettings">
+ <property name="minimumSize">
+ <size>
+ <width>125</width>
+ <height>32</height>
+ </size>
+ </property>
+ <property name="contextMenuPolicy">
+ <enum>Qt::NoContextMenu</enum>
+ </property>
+ <property name="toolTip">
+ <string>Cancels changes made to settings</string>
+ </property>
+ <property name="text">
+ <string>Cancel</string>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </item>
</layout>
</widget>
</item>
- <item row="1" column="1" colspan="2">
+ <item row="1" column="2">
<widget class="QGroupBox" name="grpSaveNewLog">
<property name="contextMenuPolicy">
<enum>Qt::NoContextMenu</enum>
@@ -385,8 +449,24 @@
</layout>
</widget>
</item>
+ <item row="0" column="0">
+ <spacer name="verticalSpacer">
+ <property name="orientation">
+ <enum>Qt::Vertical</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>0</width>
+ <height>40</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
</layout>
</item>
+ <item row="0" column="2">
+ <layout class="QVBoxLayout" name="verticalLayout"/>
+ </item>
</layout>
<action name="actionMessage_Filters">
<property name="text">
@@ -614,5 +694,21 @@
</hint>
</hints>
</connection>
+ <connection>
+ <sender>chkFilterSearch</sender>
+ <signal>toggled(bool)</signal>
+ <receiver>lineSearchTerm</receiver>
+ <slot>setEnabled(bool)</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>82</x>
+ <y>238</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>284</x>
+ <y>265</y>
+ </hint>
+ </hints>
+ </connection>
</connections>
</ui>
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits