redesigned little bit Peer Details

fixed qss stylesheets for lots of QPushButton's
removed not needed sources

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@487 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
defnax 2008-04-08 00:31:46 +00:00
parent 3f5966f2c0
commit 2d6af0b4c1
15 changed files with 614 additions and 554 deletions

View File

@ -49,6 +49,7 @@
/* Images for context menu icons */
#define IMAGE_REMOVEFRIEND ":/images/removefriend16.png"
#define IMAGE_EXPIORTFRIEND ":/images/exportpeers_16x16.png"
#define IMAGE_PEERINFO ":/images/peerdetails_16x16.png"
#define IMAGE_CHAT ":/images/chat.png"
#define IMAGE_MSG ":/images/message-mail.png"
/* Images for Status icons */
@ -117,7 +118,7 @@ void PeersDialog::peertreeWidgetCostumPopupMenu( QPoint point )
connectfriendAct = new QAction( tr( "Connect To Friend" ), this );
connect( connectfriendAct , SIGNAL( triggered() ), this, SLOT( connectfriend() ) );
configurefriendAct = new QAction( tr( "Configure Friend" ), this );
configurefriendAct = new QAction(QIcon(IMAGE_PEERINFO), tr( "Peer Details" ), this );
connect( configurefriendAct , SIGNAL( triggered() ), this, SLOT( configurefriend() ) );
exportfriendAct = new QAction(QIcon(IMAGE_EXPIORTFRIEND), tr( "Export Friend" ), this );
@ -131,9 +132,9 @@ void PeersDialog::peertreeWidgetCostumPopupMenu( QPoint point )
contextMnu.addAction( chatAct);
contextMnu.addAction( msgAct);
contextMnu.addSeparator();
contextMnu.addAction( connectfriendAct);
contextMnu.addSeparator();
contextMnu.addAction( configurefriendAct);
contextMnu.addSeparator();
contextMnu.addAction( connectfriendAct);
contextMnu.addAction( exportfriendAct);
contextMnu.addAction( removefriendAct);
contextMnu.exec( mevent->globalPos() );

View File

@ -28,7 +28,7 @@
/** Default constructor */
ConfCertDialog::ConfCertDialog(QWidget *parent, Qt::WFlags flags)
: QMainWindow(parent, flags)
: QDialog(parent, flags)
{
/* Invoke Qt Designer generated QObject setup routine */
ui.setupUi(this);
@ -38,7 +38,7 @@ ConfCertDialog::ConfCertDialog(QWidget *parent, Qt::WFlags flags)
connect(ui.cancelButton, SIGNAL(clicked()), this, SLOT(closeinfodlg()));
setFixedSize(QSize(434, 462));
//setFixedSize(QSize(434, 462));
}
@ -51,7 +51,7 @@ ConfCertDialog::show()
{
//loadSettings();
if(!this->isVisible()) {
QMainWindow::show();
QDialog::show();
}
}

View File

@ -23,11 +23,11 @@
#ifndef _CONFCERTDIALOG_H
#define _CONFCERTDIALOG_H
#include <QMainWindow>
#include <QDialog>
#include "ui_ConfCertDialog.h"
class ConfCertDialog : public QMainWindow
class ConfCertDialog : public QDialog
{
Q_OBJECT

View File

@ -1,12 +1,12 @@
<ui version="4.0" >
<class>ConfCertDialog</class>
<widget class="QWidget" name="ConfCertDialog" >
<widget class="QDialog" name="ConfCertDialog" >
<property name="geometry" >
<rect>
<x>0</x>
<y>0</y>
<width>425</width>
<height>449</height>
<width>510</width>
<height>445</height>
</rect>
</property>
<property name="sizePolicy" >
@ -498,93 +498,88 @@
<property name="contextMenuPolicy" >
<enum>Qt::NoContextMenu</enum>
</property>
<property name="windowTitle" >
<string>Details</string>
</property>
<property name="windowIcon" >
<iconset resource="../images.qrc" >:/images/rstray3.png</iconset>
</property>
<widget class="QGroupBox" name="groupBox_3" >
<property name="geometry" >
<rect>
<x>9</x>
<y>279</y>
<width>407</width>
<height>127</height>
</rect>
<layout class="QGridLayout" >
<item row="0" column="0" >
<widget class="QTabWidget" name="stabWidget" >
<property name="currentIndex" >
<number>0</number>
</property>
<widget class="QWidget" name="tab" >
<attribute name="title" >
<string>Details</string>
</attribute>
<attribute name="icon" >
<iconset resource="../images.qrc" >:/images/peerdetails_16x16.png</iconset>
</attribute>
<layout class="QGridLayout" >
<item row="0" column="0" >
<widget class="QGroupBox" name="groupBox_2" >
<property name="title" >
<string>Trust Settings</string>
<string>Peer Info</string>
</property>
<layout class="QGridLayout" >
<item row="0" column="0" >
<widget class="QLabel" name="label_9" >
<widget class="QLabel" name="label_10" >
<property name="text" >
<string>Trust Level</string>
<string>&lt;html>&lt;head>&lt;meta name="qrichtext" content="1" />&lt;style type="text/css">
p, li { white-space: pre-wrap; }
&lt;/style>&lt;/head>&lt;body style=" font-family:'Arial'; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;">
&lt;p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Name:&lt;/p>&lt;/body>&lt;/html></string>
</property>
</widget>
</item>
<item row="0" column="1" >
<widget class="QLineEdit" name="trustLvl" >
<widget class="QLineEdit" name="name" >
<property name="readOnly" >
<bool>true</bool>
</property>
</widget>
</item>
<item row="1" column="1" >
<widget class="QCheckBox" name="signBox" >
<item row="1" column="0" >
<widget class="QLabel" name="label_11" >
<property name="text" >
<string>Sign The Certificate</string>
<string>&lt;html>&lt;head>&lt;meta name="qrichtext" content="1" />&lt;style type="text/css">
p, li { white-space: pre-wrap; }
&lt;/style>&lt;/head>&lt;body style=" font-family:'Arial'; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;">
&lt;p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Org / Loc:&lt;/p>&lt;/body>&lt;/html></string>
</property>
</widget>
</item>
<item row="1" column="1" >
<widget class="QLineEdit" name="orgloc" >
<property name="readOnly" >
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0" >
<widget class="QLabel" name="label_8" >
<property name="text" >
<string>&lt;html>&lt;head>&lt;meta name="qrichtext" content="1" />&lt;style type="text/css">
p, li { white-space: pre-wrap; }
&lt;/style>&lt;/head>&lt;body style=" font-family:'Arial'; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;">
&lt;p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Country/State:&lt;/p>&lt;/body>&lt;/html></string>
</property>
</widget>
</item>
<item row="2" column="1" >
<widget class="QCheckBox" name="trustBox" >
<property name="text" >
<string>Trust Their Signature</string>
<widget class="QLineEdit" name="country" >
<property name="readOnly" >
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QPushButton" name="cancelButton" >
<property name="geometry" >
<rect>
<x>9</x>
<y>415</y>
<width>199</width>
<height>25</height>
</rect>
</property>
<property name="text" >
<string>Cancel</string>
</property>
</widget>
<widget class="QPushButton" name="applyButton" >
<property name="geometry" >
<rect>
<x>218</x>
<y>415</y>
<width>198</width>
<height>25</height>
</rect>
</property>
<property name="text" >
<string>OK</string>
</property>
<property name="autoDefault" >
<bool>false</bool>
</property>
<property name="default" >
<bool>true</bool>
</property>
</widget>
</item>
<item row="1" column="0" >
<widget class="QGroupBox" name="groupBox" >
<property name="geometry" >
<rect>
<x>9</x>
<y>143</y>
<width>407</width>
<height>127</height>
</rect>
</property>
<property name="title" >
<string>Peer Address</string>
</property>
@ -737,72 +732,86 @@ p, li { white-space: pre-wrap; }
</item>
</layout>
</widget>
<widget class="QGroupBox" name="groupBox_2" >
<property name="geometry" >
<rect>
<x>9</x>
<y>7</y>
<width>407</width>
<height>127</height>
</rect>
</property>
</item>
<item row="2" column="0" >
<widget class="QGroupBox" name="groupBox_3" >
<property name="title" >
<string>Peer Info</string>
<string>Trust Settings</string>
</property>
<layout class="QGridLayout" >
<item row="0" column="0" >
<widget class="QLabel" name="label_10" >
<widget class="QLabel" name="label_9" >
<property name="text" >
<string>&lt;html>&lt;head>&lt;meta name="qrichtext" content="1" />&lt;style type="text/css">
p, li { white-space: pre-wrap; }
&lt;/style>&lt;/head>&lt;body style=" font-family:'Arial'; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;">
&lt;p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Name:&lt;/p>&lt;/body>&lt;/html></string>
<string>Trust Level</string>
</property>
</widget>
</item>
<item row="0" column="1" >
<widget class="QLineEdit" name="name" >
<widget class="QLineEdit" name="trustLvl" >
<property name="readOnly" >
<bool>true</bool>
</property>
</widget>
</item>
<item row="1" column="0" >
<widget class="QLabel" name="label_11" >
<property name="text" >
<string>&lt;html>&lt;head>&lt;meta name="qrichtext" content="1" />&lt;style type="text/css">
p, li { white-space: pre-wrap; }
&lt;/style>&lt;/head>&lt;body style=" font-family:'Arial'; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;">
&lt;p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Org / Loc:&lt;/p>&lt;/body>&lt;/html></string>
</property>
</widget>
</item>
<item row="1" column="1" >
<widget class="QLineEdit" name="orgloc" >
<property name="readOnly" >
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0" >
<widget class="QLabel" name="label_8" >
<widget class="QCheckBox" name="signBox" >
<property name="text" >
<string>&lt;html>&lt;head>&lt;meta name="qrichtext" content="1" />&lt;style type="text/css">
p, li { white-space: pre-wrap; }
&lt;/style>&lt;/head>&lt;body style=" font-family:'Arial'; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;">
&lt;p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Country/State:&lt;/p>&lt;/body>&lt;/html></string>
<string>Sign The Certificate</string>
</property>
</widget>
</item>
<item row="2" column="1" >
<widget class="QLineEdit" name="country" >
<property name="readOnly" >
<bool>true</bool>
<widget class="QCheckBox" name="trustBox" >
<property name="text" >
<string>Trust Their Signature</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</widget>
</item>
<item row="1" column="0" >
<layout class="QGridLayout" >
<item row="0" column="0" >
<spacer>
<property name="orientation" >
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" >
<size>
<width>311</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="1" >
<widget class="QPushButton" name="cancelButton" >
<property name="text" >
<string>Cancel</string>
</property>
</widget>
</item>
<item row="0" column="2" >
<widget class="QPushButton" name="applyButton" >
<property name="text" >
<string>OK</string>
</property>
<property name="autoDefault" >
<bool>false</bool>
</property>
<property name="default" >
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</widget>
<tabstops>
<tabstop>name</tabstop>

View File

@ -13,44 +13,26 @@ QToolBar {
}
QPushButton#addfriendButton {
color: white;
min-height: 34px;
min-width: 48px;
}
QPushButton#invitefriendButton {
color: white;
min-height: 34px;
min-width: 48px;
}
QPushButton#addshareButton {
color: white;
min-height: 34px;
min-width: 48px;
}
QPushButton#optionsButton {
color: white;
min-height: 34px;
min-width: 48px;
}
QPushButton#quitButton {
color: white;
min-height: 34px;
min-width: 48px;
}
QPushButton#okButton {
color: white;
min-height: 27px;
min-width: 77px;
}
QPushButton#cancelprefButton {
min-height: 27px;
min-width: 77px;
}
QPushButton#cancelButton {
color: white;
min-height: 25px;
max-height: 25px;
min-width: 75px;
}
QPushButton#applyButton {
min-height: 25px;
max-height: 25px;
min-width: 75px;
}

View File

@ -18,35 +18,6 @@ QPushButton {
}
QPushButton#addfriendButton {
color: white;
min-height: 34px;
min-width: 48px;
}
QPushButton#invitefriendButton {
color: white;
min-height: 34px;
min-width: 48px;
}
QPushButton#addshareButton {
color: white;
min-height: 34px;
min-width: 48px;
}
QPushButton#optionsButton {
color: white;
min-height: 34px;
min-width: 48px;
}
QPushButton#quitButton {
color: white;
min-height: 34px;
min-width: 48px;
}
QPushButton#okButton {
color: white;
@ -54,7 +25,20 @@ QPushButton#okButton {
min-width: 77px;
}
QPushButton#cancelButton#afcancelButton#doneButton {
QPushButton#applyButton {
min-height: 25px;
min-width: 77px;
}
QPushButton#cancelButton {
min-height: 25px;
min-width: 77px;
}
QPushButton#afcancelButton#doneButton#refreshButtonv#nviewsettingsButton#checkButton
{
color: white;
min-height: 25px;
min-width: 75px;
@ -68,7 +52,7 @@ QPushButton#fileButton#emailButton {
QPushButton#cancelprefButton {
color: white;
min-height: 25px;
min-height: 27px;
min-width: 75px;
}
@ -82,6 +66,42 @@ QPushButton#pushButtonDownload{
min-width: 34px;
}
QPushButton#Sendbtn {
min-height: 25px;
min-width: 77px;
}
QPushButton#sendButton {
min-height: 25px;
min-width: 77px;
}
QPushButton#newmessageButton{
min-height: 27px;
min-width: 47px;
}
QPushButton#replymessageButton{
min-height: 27px;
min-width: 47px;
}
QPushButton#removemessageButton{
min-height: 27px;
min-width: 47px;
}
QPushButton#printbutton{
min-height: 27px;
min-width: 47px;
}
QPushButton
{
border-image: url(qss/black/button.png) ;

View File

@ -9,38 +9,29 @@ QToolBar {
}
QPushButton#addfriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#invitefriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#addshareButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#optionsButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#quitButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#okButton {
min-height: 27px;
min-width: 77px;
}
QPushButton#cancelprefButton {
min-height: 27px;
min-width: 77px;
}
QPushButton#cancelButton {
min-height: 25px;
max-height: 25px;
min-width: 75px;
}
QPushButton#applyButton {
min-height: 25px;
max-height: 25px;
min-width: 75px;
}
@ -48,4 +39,3 @@ QPushButton#cancelButton {

View File

@ -8,37 +8,39 @@ QToolBar {
}
QPushButton#addfriendButton {
min-height: 34px;
min-width: 48px;
/* Customize the Menu Bar. */
QMenuBar {
border-image: url(:/qss/default/retrotoolbar.png);
}
QPushButton#invitefriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#addshareButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#optionsButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#quitButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#okButton {
min-height: 27px;
min-width: 77px;
max-width: 77px;
}
QPushButton#cancelprefButton {
min-height: 27px;
min-width: 77px;
max-width: 77px;
}
QPushButton#applyButton {
min-height: 25px;
max-height: 25px;
min-width: 77px;
max-width: 77px;
}
QPushButton#cancelButton {
min-height: 25px;
min-width: 75px;
max-height: 25px;
min-width: 77px;
max-width: 77px;
}

View File

@ -31,31 +31,6 @@ border-image: url(qss/ed2k/button-up.png) ;
}
QPushButton#addfriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#invitefriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#addshareButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#optionsButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#quitButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#okButton {
min-height: 27px;
min-width: 77px;
@ -71,3 +46,78 @@ QPushButton#cancelprefButton {
min-height: 25px;
min-width: 75px;
}
QPushButton#applyButton {
min-height: 25px;
max-height: 25px;
min-width: 75px;
}
QPushButton#cancelprefButton {
min-height: 27px;
min-width: 75px;
}
QPushButton#Sendbtn {
min-height: 25px;
min-width: 77px;
}
QPushButton#sendButton {
min-height: 25px;
min-width: 77px;
}
QPushButton#newmessageButton{
min-height: 27px;
min-width: 47px;
}
QPushButton#replymessageButton{
min-height: 27px;
min-width: 47px;
}
QPushButton#removemessageButton{
min-height: 27px;
min-width: 47px;
}
QPushButton#printbutton
{
min-height: 27px;
min-width: 47px;
}
QPushButton#afcancelButton
{
min-height: 25px;
min-width: 75px;
}
QPushButton#refreshButton
{
min-height: 25px;
min-width: 75px;
}
QPushButton#checkButton
{
min-height: 25px;
min-width: 75px;
}
QPushButton#nviewsettingsButton
{
min-height: 25px;
min-width: 75px;
}

View File

@ -32,30 +32,6 @@ color: white;
border-image: url(qss/over/greentop.png) ;
}
QPushButton#addfriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#invitefriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#addshareButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#optionsButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#quitButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#okButton {
min-height: 27px;
@ -67,8 +43,76 @@ QPushButton#cancelButton {
min-width: 75px;
}
QPushButton#applyButton {
min-height: 25px;
max-height: 25px;
min-width: 75px;
}
QPushButton#cancelprefButton {
color: white;
min-height: 27px;
min-width: 75px;
}
QPushButton#Sendbtn {
min-height: 25px;
min-width: 77px;
}
QPushButton#sendButton {
min-height: 25px;
min-width: 77px;
}
QPushButton#newmessageButton{
min-height: 27px;
min-width: 47px;
}
QPushButton#replymessageButton{
min-height: 27px;
min-width: 47px;
}
QPushButton#removemessageButton{
min-height: 27px;
min-width: 47px;
}
QPushButton#printbutton
{
min-height: 27px;
min-width: 47px;
}
QPushButton#afcancelButton
{
min-height: 25px;
min-width: 75px;
}
QPushButton#refreshButton
{
min-height: 25px;
min-width: 75px;
}
QPushButton#checkButton
{
min-height: 25px;
min-width: 75px;
}
QPushButton#nviewsettingsButton
{
min-height: 25px;
min-width: 75px;
}

View File

@ -7,39 +7,26 @@ QToolBar {
QPushButton#addfriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#invitefriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#addshareButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#optionsButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#quitButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#okButton {
min-height: 27px;
min-width: 77px;
}
QPushButton#cancelprefButton {
min-height: 27px;
min-width: 77px;
}
QPushButton#cancelButton {
min-height: 25px;
max-height: 25px;
min-width: 75px;
}
QPushButton#applyButton {
min-height: 25px;
max-height: 25px;
min-width: 75px;
}

View File

@ -7,37 +7,26 @@ QToolBar {
}
QPushButton#addfriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#invitefriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#addshareButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#optionsButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#quitButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#okButton {
min-height: 27px;
min-width: 77px;
}
QPushButton#cancelprefButton {
min-height: 27px;
min-width: 77px;
}
QPushButton#cancelButton {
min-height: 25px;
max-height: 25px;
min-width: 75px;
}
QPushButton#applyButton {
min-height: 25px;
max-height: 25px;
min-width: 75px;
}

View File

@ -6,41 +6,28 @@ QToolBar {
}
QPushButton#addfriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#invitefriendButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#addshareButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#optionsButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#quitButton {
min-height: 34px;
min-width: 48px;
}
QPushButton#okButton {
min-height: 27px;
min-width: 77px;
}
QPushButton#cancelprefButton {
min-height: 27px;
min-width: 77px;
}
QPushButton#cancelButton {
min-height: 25px;
max-height: 25px;
min-width: 75px;
}
QPushButton#applyButton {
min-height: 25px;
max-height: 25px;
min-width: 75px;
}

View File

@ -21,14 +21,13 @@
#include <util/AnimatedButton.h>
//#include <util/SafeConnect.h>
//#include <util/SafeDelete.h>
#include <QtGui/QtGui>
static const char * MNG_FORMAT = "MNG";
AnimatedButton::AnimatedButton(QAbstractButton * button, const QString & animatedIconFilename) {
AnimatedButton::AnimatedButton(QToolButton * button, const QString & animatedIconFilename) {
_button = button;
_animatedIcon = new QMovie(animatedIconFilename, MNG_FORMAT, _button);
connect(_animatedIcon, SIGNAL(frameChanged(int)), SLOT(updateButtonIcon()));

View File

@ -28,7 +28,7 @@
#include <QtCore/QObject>
class QAbstractButton;
class QToolButton;
class QMovie;
class QString;
@ -49,7 +49,7 @@ public:
* @param button button' icon to animate
* @param animatedIconFilename mng filename to animate the button icon
*/
AnimatedButton(QAbstractButton * button, const QString & animatedIconFilename);
AnimatedButton(QToolButton * button, const QString & animatedIconFilename);
~AnimatedButton();
@ -62,7 +62,7 @@ private Q_SLOTS:
private:
QAbstractButton * _button;
QToolButton * _button;
QMovie * _animatedIcon;
};