The branch, master has been updated via 3f2d20b4cc2804a5cd0b68e6f3113c1d9bbf53e4 (commit) from 95f154232125bbd92fa573e67f40f7b56765971c (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 3f2d20b4cc2804a5cd0b68e6f3113c1d9bbf53e4 Author: Oleksandr Shneyder <o.shneyder@phoca-gmbh.de> Date: Tue Feb 19 15:32:05 2013 +0100 continue developing SessionStatusForm ----------------------------------------------------------------------- Summary of changes: mainwindow.h | 2 +- profile.ui | 3 + sessionstatusframe.cpp | 18 +- sessionstatusframe.h | 8 +- sessionstatusframe.ui | 278 +------------------- ...chbar.cpp => sessionstatusframeapplications.cpp | 9 +- searchbar.h => sessionstatusframeapplications.h | 22 +- sessionstatusframeapplications.ui | 134 ++++++++++ sessionstatusframestatus.cpp | 78 ++++++ sessionstatusframe.h => sessionstatusframestatus.h | 21 +- sessionstatusframestatus.ui | 256 ++++++++++++++++++ x2goapplication.cpp | 8 +- x2goapplication.h | 6 +- x2goclient2.pro | 6 + 14 files changed, 539 insertions(+), 310 deletions(-) copy searchbar.cpp => sessionstatusframeapplications.cpp (82%) copy searchbar.h => sessionstatusframeapplications.h (75%) create mode 100644 sessionstatusframeapplications.ui create mode 100644 sessionstatusframestatus.cpp copy sessionstatusframe.h => sessionstatusframestatus.h (74%) create mode 100644 sessionstatusframestatus.ui The diff of changes is: diff --git a/mainwindow.h b/mainwindow.h index 30b40c6..9dba613 100644 --- a/mainwindow.h +++ b/mainwindow.h @@ -1,5 +1,5 @@ /************************************************************************** -* Copyright (C) 2005-2012 by Oleksandr Shneyder * +* Copyright (C) 2005-2013 by Oleksandr Shneyder * * oleksandr.shneyder@obviously-nice.de * * * * This program is free software; you can redistribute it and/or modify * diff --git a/profile.ui b/profile.ui index 700d80a..6a74f7c 100644 --- a/profile.ui +++ b/profile.ui @@ -83,6 +83,9 @@ </item> <item> <layout class="QVBoxLayout" name="verticalLayout"> + <property name="leftMargin"> + <number>8</number> + </property> <property name="rightMargin"> <number>0</number> </property> diff --git a/sessionstatusframe.cpp b/sessionstatusframe.cpp index 270e1fd..6ad9691 100644 --- a/sessionstatusframe.cpp +++ b/sessionstatusframe.cpp @@ -1,5 +1,5 @@ /************************************************************************** -* Copyright (C) 2005-2012 by Oleksandr Shneyder * +* Copyright (C) 2005-2013 by Oleksandr Shneyder * * o.shneyder@phoca-gmbh.de * * * * This program is free software; you can redistribute it and/or modify * @@ -19,14 +19,19 @@ ***************************************************************************/ #include "sessionstatusframe.h" -#include <QScrollBar> + +#include "sessionstatusframestatus.h" +#include "sessionstatusframeapplications.h" + SessionStatusFrame::SessionStatusFrame(QWidget* parent, Qt::WindowFlags f): QFrame(parent, f) { setupUi(this); - teAdvancedStatus->hide(); - teAdvancedStatus->verticalScrollBar()->setStyleSheet( - "background-color:transparent;border-top:0px;border-left:0px;border-right:0px;border-bottom:0px"); + + frStatus=new SessionStatusFrameStatus(this); + frApps=new SessionStatusFrameApplications(this); + ((QVBoxLayout*)layout())->addWidget(frStatus); + ((QVBoxLayout*)layout())->addWidget(frApps); setFrame(pbStatus); } @@ -40,6 +45,7 @@ void SessionStatusFrame::slotSetTabFrames() setFrame(pbApps); setFrame(pbFolders); setFrame(pbStatus); + frStatus->checkWorkAreaScrolling(); } void SessionStatusFrame::setFrame(QPushButton* button) @@ -48,4 +54,6 @@ void SessionStatusFrame::setFrame(QPushButton* button) button->setStyleSheet("border-image:url(:svg/frame.svg);border-top:5px;border-left:5px;border-right:5px;border-bottom:5px"); else button->setStyleSheet("border-image:url(:svg/transparent.svg);border-top:5px;border-left:5px;border-right:5px;border-bottom:5px"); + frStatus->setVisible(pbStatus->isChecked()); + frApps->setVisible(pbApps->isChecked()); } diff --git a/sessionstatusframe.h b/sessionstatusframe.h index 02fc804..39f9be9 100644 --- a/sessionstatusframe.h +++ b/sessionstatusframe.h @@ -1,5 +1,5 @@ /************************************************************************** -* Copyright (C) 2005-2012 by Oleksandr Shneyder * +* Copyright (C) 2005-2013 by Oleksandr Shneyder * * o.shneyder@phoca-gmbh.de * * * * This program is free software; you can redistribute it and/or modify * @@ -24,6 +24,9 @@ #include <QFrame> #include "ui_sessionstatusframe.h" +class SessionStatusFrameStatus; +class SessionStatusFrameApplications; + class SessionStatusFrame : public QFrame, public Ui_SessionStatusFrame { Q_OBJECT @@ -34,6 +37,9 @@ private slots: void slotSetTabFrames(); private: void setFrame(QPushButton* button); +private: + SessionStatusFrameStatus* frStatus; + SessionStatusFrameApplications* frApps; }; #endif // SESSIONSTATUSFRAME_H diff --git a/sessionstatusframe.ui b/sessionstatusframe.ui index 9f0bf87..b748ad4 100644 --- a/sessionstatusframe.ui +++ b/sessionstatusframe.ui @@ -6,8 +6,8 @@ <rect> <x>0</x> <y>0</y> - <width>644</width> - <height>415</height> + <width>571</width> + <height>99</height> </rect> </property> <property name="windowTitle"> @@ -23,6 +23,12 @@ <enum>QFrame::Raised</enum> </property> <layout class="QVBoxLayout" name="verticalLayout_2"> + <property name="leftMargin"> + <number>5</number> + </property> + <property name="rightMargin"> + <number>5</number> + </property> <item> <layout class="QHBoxLayout" name="horizontalLayout"> <property name="spacing"> @@ -103,236 +109,6 @@ </item> </layout> </item> - <item> - <widget class="QGroupBox" name="groupBox"> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="title"> - <string/> - </property> - <layout class="QVBoxLayout" name="verticalLayout"> - <item> - <layout class="QGridLayout" name="gridLayout"> - <property name="horizontalSpacing"> - <number>10</number> - </property> - <item row="1" column="1"> - <widget class="QLabel" name="lServer"> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string/> - </property> - </widget> - </item> - <item row="3" column="0"> - <widget class="QLabel" name="label_4"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string>Session ID:</string> - </property> - </widget> - </item> - <item row="5" column="1"> - <widget class="QLabel" name="lCrTime"> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string/> - </property> - </widget> - </item> - <item row="4" column="0"> - <widget class="QLabel" name="label_5"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string>Display:</string> - </property> - </widget> - </item> - <item row="4" column="1"> - <widget class="QLabel" name="lDisplay"> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string/> - </property> - </widget> - </item> - <item row="2" column="0"> - <widget class="QLabel" name="label_3"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string>Login:</string> - </property> - </widget> - </item> - <item row="3" column="1"> - <widget class="QLabel" name="lSID"> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string/> - </property> - </widget> - </item> - <item row="5" column="0"> - <widget class="QLabel" name="label_11"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string>Creation time:</string> - </property> - </widget> - </item> - <item row="0" column="1"> - <widget class="QLabel" name="lStatus"> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string>not running</string> - </property> - </widget> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="label_2"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string>Server:</string> - </property> - </widget> - </item> - <item row="0" column="0"> - <widget class="QLabel" name="label"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string>Status:</string> - </property> - </widget> - </item> - <item row="2" column="1"> - <widget class="QLabel" name="lLogin"> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string/> - </property> - </widget> - </item> - <item row="0" column="2"> - <spacer name="horizontalSpacer_2"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>40</width> - <height>20</height> - </size> - </property> - </spacer> - </item> - </layout> - </item> - <item> - <spacer name="verticalSpacer"> - <property name="orientation"> - <enum>Qt::Vertical</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>20</width> - <height>40</height> - </size> - </property> - </spacer> - </item> - <item> - <widget class="QTextEdit" name="teAdvancedStatus"> - <property name="styleSheet"> - <string notr="true">border-image:url(:svg/frame.svg);border-top:1px;border-left:1px;border-right:1px;border-bottom:1px</string> - </property> - <property name="frameShape"> - <enum>QFrame::NoFrame</enum> - </property> - <property name="verticalScrollBarPolicy"> - <enum>Qt::ScrollBarAsNeeded</enum> - </property> - <property name="horizontalScrollBarPolicy"> - <enum>Qt::ScrollBarAlwaysOff</enum> - </property> - <property name="readOnly"> - <bool>true</bool> - </property> - </widget> - </item> - <item> - <widget class="QCheckBox" name="checkBox"> - <property name="styleSheet"> - <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> - </property> - <property name="text"> - <string>Show details</string> - </property> - </widget> - </item> - </layout> - </widget> - </item> </layout> </widget> <resources> @@ -340,22 +116,6 @@ </resources> <connections> <connection> - <sender>checkBox</sender> - <signal>toggled(bool)</signal> - <receiver>teAdvancedStatus</receiver> - <slot>setVisible(bool)</slot> - <hints> - <hint type="sourcelabel"> - <x>99</x> - <y>364</y> - </hint> - <hint type="destinationlabel"> - <x>147</x> - <y>277</y> - </hint> - </hints> - </connection> - <connection> <sender>pbStatus</sender> <signal>toggled(bool)</signal> <receiver>SessionStatusFrame</receiver> @@ -367,7 +127,7 @@ </hint> <hint type="destinationlabel"> <x>19</x> - <y>200</y> + <y>98</y> </hint> </hints> </connection> @@ -383,7 +143,7 @@ </hint> <hint type="destinationlabel"> <x>17</x> - <y>248</y> + <y>98</y> </hint> </hints> </connection> @@ -399,23 +159,7 @@ </hint> <hint type="destinationlabel"> <x>13</x> - <y>299</y> - </hint> - </hints> - </connection> - <connection> - <sender>pbStatus</sender> - <signal>toggled(bool)</signal> - <receiver>groupBox</receiver> - <slot>setVisible(bool)</slot> - <hints> - <hint type="sourcelabel"> - <x>62</x> - <y>42</y> - </hint> - <hint type="destinationlabel"> - <x>40</x> - <y>89</y> + <y>98</y> </hint> </hints> </connection> diff --git a/searchbar.cpp b/sessionstatusframeapplications.cpp similarity index 82% copy from searchbar.cpp copy to sessionstatusframeapplications.cpp index e3bb525..249bbcc 100644 --- a/searchbar.cpp +++ b/sessionstatusframeapplications.cpp @@ -1,5 +1,5 @@ /************************************************************************** -* Copyright (C) 2005-2012 by Oleksandr Shneyder * +* Copyright (C) 2005-2013 by Oleksandr Shneyder * * o.shneyder@phoca-gmbh.de * * * * This program is free software; you can redistribute it and/or modify * @@ -19,15 +19,14 @@ ***************************************************************************/ -#include "searchbar.h" +#include "sessionstatusframeapplications.h" -SearchBar::SearchBar(QWidget* parent, Qt::WindowFlags f): QFrame( parent, f) +SessionStatusFrameApplications::SessionStatusFrameApplications(QWidget* parent, Qt::WindowFlags f): QFrame(parent, f) { setupUi(this); - lineEdit->setFocus(); } -SearchBar::~SearchBar() +SessionStatusFrameApplications::~SessionStatusFrameApplications() { } diff --git a/searchbar.h b/sessionstatusframeapplications.h similarity index 75% copy from searchbar.h copy to sessionstatusframeapplications.h index d859cc7..4fc8567 100644 --- a/searchbar.h +++ b/sessionstatusframeapplications.h @@ -1,5 +1,5 @@ /************************************************************************** -* Copyright (C) 2005-2012 by Oleksandr Shneyder * +* Copyright (C) 2005-2013 by Oleksandr Shneyder * * o.shneyder@phoca-gmbh.de * * * * This program is free software; you can redistribute it and/or modify * @@ -18,23 +18,19 @@ * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * ***************************************************************************/ -#ifndef SEARCHBAR_H -#define SEARCHBAR_H + +#ifndef SESSIONSTATUSFRAMEAPPLICATIONS_H +#define SESSIONSTATUSFRAMEAPPLICATIONS_H #include <QFrame> -#include "ui_searchbar.h" +#include "ui_sessionstatusframeapplications.h" -class SearchBar : public QFrame, public Ui_searchBar +class SessionStatusFrameApplications : public QFrame, public Ui_SessionStatusFrameApplications { Q_OBJECT public: - SearchBar(QWidget* parent = 0, Qt::WindowFlags f = 0); - ~SearchBar(); - QLineEdit* getLineEdit() - { - return lineEdit; - } - + explicit SessionStatusFrameApplications(QWidget* parent = 0, Qt::WindowFlags f = 0); + virtual ~SessionStatusFrameApplications(); }; -#endif // SEARCHBAR_H +#endif // SESSIONSTATUSFRAMEAPPLICATIONS_H diff --git a/sessionstatusframeapplications.ui b/sessionstatusframeapplications.ui new file mode 100644 index 0000000..dc26415 --- /dev/null +++ b/sessionstatusframeapplications.ui @@ -0,0 +1,134 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ui version="4.0"> + <class>SessionStatusFrameApplications</class> + <widget class="QFrame" name="SessionStatusFrameApplications"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>459</width> + <height>339</height> + </rect> + </property> + <property name="windowTitle"> + <string>Frame</string> + </property> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="frameShape"> + <enum>QFrame::StyledPanel</enum> + </property> + <property name="frameShadow"> + <enum>QFrame::Raised</enum> + </property> + <layout class="QHBoxLayout" name="horizontalLayout_2"> + <property name="margin"> + <number>0</number> + </property> + <item> + <layout class="QVBoxLayout" name="verticalLayout_2"> + <item> + <widget class="QTreeWidget" name="treeWidget"> + <property name="styleSheet"> + <string notr="true">border-image:url(:svg/frame.svg);border-top:1px;border-left:1px;border-right:1px;border-bottom:1px</string> + </property> + <property name="iconSize"> + <size> + <width>22</width> + <height>22</height> + </size> + </property> + <property name="rootIsDecorated"> + <bool>true</bool> + </property> + <property name="uniformRowHeights"> + <bool>true</bool> + </property> + <property name="itemsExpandable"> + <bool>true</bool> + </property> + <property name="sortingEnabled"> + <bool>false</bool> + </property> + <property name="expandsOnDoubleClick"> + <bool>false</bool> + </property> + <attribute name="headerVisible"> + <bool>false</bool> + </attribute> + <column> + <property name="text"> + <string notr="true">1</string> + </property> + </column> + </widget> + </item> + <item> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <widget class="QLabel" name="label"> + <property name="text"> + <string>Search:</string> + </property> + </widget> + </item> + <item> + <widget class="QLineEdit" name="lineEdit"> + <property name="styleSheet"> + <string notr="true">border-image:url(:svg/frame.svg);border-top:1px;border-left:1px;border-right:1px;border-bottom:1px</string> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </item> + <item> + <layout class="QVBoxLayout" name="verticalLayout"> + <item> + <spacer name="verticalSpacer_2"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QPushButton" name="startButton"> + <property name="focusPolicy"> + <enum>Qt::NoFocus</enum> + </property> + <property name="styleSheet"> + <string notr="true">border-image:url(:svg/frame.svg);border-top:5px;border-left:5px;border-right:5px;border-bottom:5px</string> + </property> + <property name="text"> + <string>&Start</string> + </property> + </widget> + </item> + <item> + <spacer name="verticalSpacer"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + </layout> + </item> + </layout> + </widget> + <resources/> + <connections/> +</ui> diff --git a/sessionstatusframestatus.cpp b/sessionstatusframestatus.cpp new file mode 100644 index 0000000..66926c9 --- /dev/null +++ b/sessionstatusframestatus.cpp @@ -0,0 +1,78 @@ +/************************************************************************** +* Copyright (C) 2005-2013 by Oleksandr Shneyder * +* o.shneyder@phoca-gmbh.de * +* * +* This program is free software; you can redistribute it and/or modify * +* it under the terms of the GNU General Public License as published by * +* the Free Software Foundation; either version 2 of the License, or * +* (at your option) any later version. * +* * +* This program is distributed in the hope that it will be useful, * +* but WITHOUT ANY WARRANTY; without even the implied warranty of * +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * +* GNU General Public License for more details. * +* * +* You should have received a copy of the GNU General Public License * +* along with this program; if not, write to the * +* Free Software Foundation, Inc., * +* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * +***************************************************************************/ + + +#include "sessionstatusframestatus.h" +#include <QScrollBar> +#include "x2goapplication.h" +#include "workarea.h" + +SessionStatusFrameStatus::SessionStatusFrameStatus(QWidget* parent, Qt::WindowFlags f): QFrame(parent, f) +{ + setupUi(this); + teAdvancedStatus->hide(); + + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + teAdvancedStatus->append("yxcyxjcbnmsdbamfnbsdmnfbmnsad\nardjgjhasdgjhasdg\nasdhaskjdhjkasd"); + + teAdvancedStatus->verticalScrollBar()->setStyleSheet( + "background-color:transparent;border-top:0px;border-left:0px;border-right:0px;border-bottom:0px"); + connect(cbDetails, SIGNAL(clicked()), this, SLOT(SlotDetailCliecked())); +} + +SessionStatusFrameStatus::~SessionStatusFrameStatus() +{ + +} + +void SessionStatusFrameStatus::SlotDetailCliecked() +{ + teAdvancedStatus->setVisible(cbDetails->isChecked()); + checkWorkAreaScrolling(); +} + +void SessionStatusFrameStatus::checkWorkAreaScrolling() +{ + X2GoApplication::instance()->get_workArea()->set_animateNextScroll(false); + X2GoApplication::instance()->get_workArea()->slotScrollToSessionForm(); +} diff --git a/sessionstatusframe.h b/sessionstatusframestatus.h similarity index 74% copy from sessionstatusframe.h copy to sessionstatusframestatus.h index 02fc804..0a1d17c 100644 --- a/sessionstatusframe.h +++ b/sessionstatusframestatus.h @@ -1,5 +1,5 @@ /************************************************************************** -* Copyright (C) 2005-2012 by Oleksandr Shneyder * +* Copyright (C) 2005-2013 by Oleksandr Shneyder * * o.shneyder@phoca-gmbh.de * * * * This program is free software; you can redistribute it and/or modify * @@ -18,22 +18,21 @@ * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * ***************************************************************************/ -#ifndef SESSIONSTATUSFRAME_H -#define SESSIONSTATUSFRAME_H +#ifndef SESSIONSTATUSFRAMESTATUS_H +#define SESSIONSTATUSFRAMESTATUS_H #include <QFrame> -#include "ui_sessionstatusframe.h" +#include "ui_sessionstatusframestatus.h" -class SessionStatusFrame : public QFrame, public Ui_SessionStatusFrame +class SessionStatusFrameStatus : public QFrame, public Ui_SessionStatusFrameStatus { Q_OBJECT public: - explicit SessionStatusFrame(QWidget* parent = 0, Qt::WindowFlags f = 0); - virtual ~SessionStatusFrame(); + explicit SessionStatusFrameStatus(QWidget* parent = 0, Qt::WindowFlags f = 0); + virtual ~SessionStatusFrameStatus(); + void checkWorkAreaScrolling(); private slots: - void slotSetTabFrames(); -private: - void setFrame(QPushButton* button); + void SlotDetailCliecked(); }; -#endif // SESSIONSTATUSFRAME_H +#endif // SESSIONSTATUSFRAMESTATUS_H diff --git a/sessionstatusframestatus.ui b/sessionstatusframestatus.ui new file mode 100644 index 0000000..9a89d54 --- /dev/null +++ b/sessionstatusframestatus.ui @@ -0,0 +1,256 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ui version="4.0"> + <class>SessionStatusFrameStatus</class> + <widget class="QFrame" name="SessionStatusFrameStatus"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>624</width> + <height>257</height> + </rect> + </property> + <property name="windowTitle"> + <string>Frame</string> + </property> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="frameShape"> + <enum>QFrame::NoFrame</enum> + </property> + <property name="frameShadow"> + <enum>QFrame::Raised</enum> + </property> + <property name="lineWidth"> + <number>2</number> + </property> + <layout class="QVBoxLayout" name="verticalLayout"> + <property name="spacing"> + <number>10</number> + </property> + <property name="margin"> + <number>0</number> + </property> + <item> + <layout class="QGridLayout" name="gridLayout"> + <property name="horizontalSpacing"> + <number>10</number> + </property> + <property name="verticalSpacing"> + <number>5</number> + </property> + <item row="1" column="1"> + <widget class="QLabel" name="lServer"> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string/> + </property> + </widget> + </item> + <item row="3" column="0"> + <widget class="QLabel" name="label_4"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string>Session ID:</string> + </property> + </widget> + </item> + <item row="5" column="1"> + <widget class="QLabel" name="lCrTime"> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string/> + </property> + </widget> + </item> + <item row="4" column="0"> + <widget class="QLabel" name="label_5"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string>Display:</string> + </property> + </widget> + </item> + <item row="4" column="1"> + <widget class="QLabel" name="lDisplay"> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string/> + </property> + </widget> + </item> + <item row="2" column="0"> + <widget class="QLabel" name="label_3"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string>Login:</string> + </property> + </widget> + </item> + <item row="3" column="1"> + <widget class="QLabel" name="lSID"> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string/> + </property> + </widget> + </item> + <item row="5" column="0"> + <widget class="QLabel" name="label_11"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string>Creation time:</string> + </property> + </widget> + </item> + <item row="0" column="1"> + <widget class="QLabel" name="lStatus"> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string>not running</string> + </property> + </widget> + </item> + <item row="1" column="0"> + <widget class="QLabel" name="label_2"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string>Server:</string> + </property> + </widget> + </item> + <item row="0" column="0"> + <widget class="QLabel" name="label"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string>Status:</string> + </property> + </widget> + </item> + <item row="2" column="1"> + <widget class="QLabel" name="lLogin"> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string/> + </property> + </widget> + </item> + <item row="0" column="2"> + <spacer name="horizontalSpacer_2"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + </layout> + </item> + <item> + <widget class="QTextEdit" name="teAdvancedStatus"> + <property name="enabled"> + <bool>true</bool> + </property> + <property name="styleSheet"> + <string notr="true">border-image:url(:svg/frame.svg);border-top:1px;border-left:1px;border-right:1px;border-bottom:1px</string> + </property> + <property name="frameShape"> + <enum>QFrame::NoFrame</enum> + </property> + <property name="verticalScrollBarPolicy"> + <enum>Qt::ScrollBarAsNeeded</enum> + </property> + <property name="horizontalScrollBarPolicy"> + <enum>Qt::ScrollBarAlwaysOff</enum> + </property> + <property name="readOnly"> + <bool>true</bool> + </property> + </widget> + </item> + <item> + <widget class="QCheckBox" name="cbDetails"> + <property name="focusPolicy"> + <enum>Qt::NoFocus</enum> + </property> + <property name="styleSheet"> + <string notr="true">border-top:0px;border-left:0px;border-right:0px;border-bottom:0px</string> + </property> + <property name="text"> + <string>Show details</string> + </property> + </widget> + </item> + </layout> + </widget> + <resources/> + <connections/> + <slots> + <slot>slotLayoutChanged()</slot> + </slots> +</ui> diff --git a/x2goapplication.cpp b/x2goapplication.cpp index bece575..ffc6992 100644 --- a/x2goapplication.cpp +++ b/x2goapplication.cpp @@ -1,5 +1,5 @@ /************************************************************************** -* Copyright (C) 2005-2012 by Oleksandr Shneyder * +* Copyright (C) 2005-2013 by Oleksandr Shneyder * * o.shneyder@phoca-gmbh.de * * * * This program is free software; you can redistribute it and/or modify * @@ -167,21 +167,21 @@ const nameTranslator* X2GoApplication::getTranslator(QList< nameTranslator >& li void X2GoApplication::initProfiles() { - QList<PSort> sortList; + QList<ProfileSortPtr> sortList; foreach(QString profileId, sessionSettings->get_setting()->childGroups()) { if(profileId=="embedded") continue; Profile* profile=new Profile(profileId, profileForm->getScrollArea()->widget()); profile->loadProfile(); - PSort psort; + ProfileSortPtr psort; psort.ptr=(void*) profile; psort.name=profile->get_profileName(); sortList<<psort; } qSort(sortList); profiles.clear(); - foreach(PSort psrt, sortList) + foreach(ProfileSortPtr psrt, sortList) { profiles<<(Profile*)psrt.ptr; } diff --git a/x2goapplication.h b/x2goapplication.h index 2cddbd9..03ca252 100644 --- a/x2goapplication.h +++ b/x2goapplication.h @@ -1,5 +1,5 @@ /************************************************************************** -* Copyright (C) 2005-2012 by Oleksandr Shneyder * +* Copyright (C) 2005-2013 by Oleksandr Shneyder * * o.shneyder@phoca-gmbh.de * * * * This program is free software; you can redistribute it and/or modify * @@ -52,11 +52,11 @@ struct nameTranslator QString internName; }; -struct PSort +struct ProfileSortPtr { void* ptr; QString name; - bool operator<(const PSort& t2) const + bool operator<(const ProfileSortPtr& t2) const { return (name.compare(t2.name, Qt::CaseInsensitive)<0); } diff --git a/x2goclient2.pro b/x2goclient2.pro index 96a814f..59167ba 100755 --- a/x2goclient2.pro +++ b/x2goclient2.pro @@ -28,6 +28,8 @@ FORMS += mainwindow.ui \ messagebox.ui \ helpdialog.ui \ sessionstatusframe.ui \ + sessionstatusframestatus.ui \ + sessionstatusframeapplications.ui \ profile.ui SOURCES += main.cpp \ @@ -60,6 +62,8 @@ SOURCES += main.cpp \ sshconnectionguiinteraction.cpp \ sshprocess.cpp \ sessionstatusframe.cpp \ + sessionstatusframestatus.cpp \ + sessionstatusframeapplications.cpp \ profile.cpp HEADERS += mainwindow.h \ @@ -91,6 +95,8 @@ HEADERS += mainwindow.h \ sshconnectionguiinteraction.h \ sshprocess.h \ sessionstatusframe.h \ + sessionstatusframestatus.h \ + sessionstatusframeapplications.h \ profile.h LIBS += -lssh hooks/post-receive -- x2goclient2.git (X2Go Client 2 (rewrite of x2goclient.git)) This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "x2goclient2.git" (X2Go Client 2 (rewrite of x2goclient.git)).