From aaca3d0300c30d6dfed2fb5d7b661191fb1633af Mon Sep 17 00:00:00 2001 From: Dirk H Bartley Date: Wed, 30 May 2007 20:39:12 +0000 Subject: [PATCH] A little bit of playing around with icons. Added context sensitve menu to the restore page in the file tree. Mark and unmark can now be done from right click. git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@4944 91ce42f0-d328-0410-95d8-f526ca767f89 --- bacula/src/qt-console/images/joblog.png | Bin 0 -> 2369 bytes bacula/src/qt-console/images/joblog.svg | 252 ++++++++++++++++++++++ bacula/src/qt-console/joblist/joblist.ui | 2 +- bacula/src/qt-console/joblog/joblog.cpp | 2 +- bacula/src/qt-console/joblog/joblog.ui | 4 +- bacula/src/qt-console/jobs/jobs.cpp | 3 +- bacula/src/qt-console/main.qrc | 1 + bacula/src/qt-console/main.ui | 2 +- bacula/src/qt-console/restore/restore.cpp | 7 + bacula/src/qt-console/restore/restore.ui | 26 ++- bacula/src/qt-console/run/run.cpp | 2 +- 11 files changed, 290 insertions(+), 11 deletions(-) create mode 100644 bacula/src/qt-console/images/joblog.png create mode 100644 bacula/src/qt-console/images/joblog.svg diff --git a/bacula/src/qt-console/images/joblog.png b/bacula/src/qt-console/images/joblog.png new file mode 100644 index 0000000000000000000000000000000000000000..6728b1dca1fbcc1c7192ff1beafd308ade0e8264 GIT binary patch literal 2369 zcmV-H3BLA;P)+3$&e*KwOSQ zfZJxEFfE3mop#DOB<++d9jHkmjMF5LIOK3_<5;p~OR_FYD`|J7)$Z#bwy94rrTu2! z?7rRa_`UD@z3=T3N+}jA?QZw7tdjSNqH1}TRaH3?KfeEw2Oe0ogL#DcBFa*Rtmm^! z({H@5?->Y`4ichi_%gv41kmnwH_i(nOE&n!Y_$8_7~ek-NoqM`-U9Zm?QS>sUjf*? z`-$E0Ov7vU-T!1~yW3qp&1nh8aVx@6B@F<)a9;oknpfNyjp4k}6jkd+nnxj%n2P>|2|Ufa6N z)Zi*}boT}iz3}oM2S7z}+s!Q@Mx|N+%Azy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O@ zm{K|dUtCA;5d~aXXR|*(#UP&!N^PhcL2ZyUsf%v_*L4X|BlXPE*taupAULQZ(XzlO6mV( n7)-_*dr84dI-}nHMeP0!X13CGV@p5300000NkvXXu0mjfhzNwJ literal 0 HcmV?d00001 diff --git a/bacula/src/qt-console/images/joblog.svg b/bacula/src/qt-console/images/joblog.svg new file mode 100644 index 0000000000..b776f6a4f5 --- /dev/null +++ b/bacula/src/qt-console/images/joblog.svg @@ -0,0 +1,252 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + Jakub Steiner + + + http://jimmac.musichall.cz + + Emblem System + + + emblem + system + library + crucial + base + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/bacula/src/qt-console/joblist/joblist.ui b/bacula/src/qt-console/joblist/joblist.ui index e9f058a36c..1b861a0ed4 100644 --- a/bacula/src/qt-console/joblist/joblist.ui +++ b/bacula/src/qt-console/joblist/joblist.ui @@ -402,7 +402,7 @@ - :/images/status.png + :/images/joblog.png Show Log for Job diff --git a/bacula/src/qt-console/joblog/joblog.cpp b/bacula/src/qt-console/joblog/joblog.cpp index a3dd9e4ab0..016929cca8 100644 --- a/bacula/src/qt-console/joblog/joblog.cpp +++ b/bacula/src/qt-console/joblog/joblog.cpp @@ -45,7 +45,7 @@ JobLog::JobLog(QString &jobId, QTreeWidgetItem *parentTreeWidgetItem) m_closeable = true; pgInitialize(parentTreeWidgetItem); QTreeWidgetItem* thisitem = mainWin->getFromHash(this); - thisitem->setIcon(0,QIcon(QString::fromUtf8(":images/emblem-system.svg"))); + thisitem->setIcon(0,QIcon(QString::fromUtf8(":images/joblog.png"))); m_cursor = new QTextCursor(textEdit->document()); m_jobId = jobId; diff --git a/bacula/src/qt-console/joblog/joblog.ui b/bacula/src/qt-console/joblog/joblog.ui index 5eb05665b4..a92397060d 100644 --- a/bacula/src/qt-console/joblog/joblog.ui +++ b/bacula/src/qt-console/joblog/joblog.ui @@ -78,6 +78,8 @@ - + + + diff --git a/bacula/src/qt-console/jobs/jobs.cpp b/bacula/src/qt-console/jobs/jobs.cpp index 2d20a1be96..ce31a381b0 100644 --- a/bacula/src/qt-console/jobs/jobs.cpp +++ b/bacula/src/qt-console/jobs/jobs.cpp @@ -46,7 +46,7 @@ Jobs::Jobs() m_name = "Jobs"; pgInitialize(); QTreeWidgetItem* thisitem = mainWin->getFromHash(this); - thisitem->setIcon(0,QIcon(QString::fromUtf8(":images/emblem-system.svg"))); + thisitem->setIcon(0,QIcon(QString::fromUtf8(":images/run.png"))); /* mp_treeWidget, Storage Tree Tree Widget inherited from ui_client.h */ m_populated = false; @@ -257,7 +257,6 @@ void Jobs::consoleCancel() void Jobs::listJobs() { - printf("In Jobs::listJobs\n"); QTreeWidgetItem *parentItem = mainWin->getFromHash(this); mainWin->createPageJobList("", "", m_currentlyselected, parentItem); } diff --git a/bacula/src/qt-console/main.qrc b/bacula/src/qt-console/main.qrc index 2667db21a9..b54c494bd5 100644 --- a/bacula/src/qt-console/main.qrc +++ b/bacula/src/qt-console/main.qrc @@ -18,6 +18,7 @@ images/folder.svg images/help-browser.svg images/home.png + images/joblog.png images/label.png images/mail-message-new.svg images/mark.png diff --git a/bacula/src/qt-console/main.ui b/bacula/src/qt-console/main.ui index 9feaab51b5..4c1704ec70 100644 --- a/bacula/src/qt-console/main.ui +++ b/bacula/src/qt-console/main.ui @@ -416,7 +416,7 @@ false - :/images/emblem-system.svg + :/images/run.png Run Job diff --git a/bacula/src/qt-console/restore/restore.cpp b/bacula/src/qt-console/restore/restore.cpp index 00c11ac447..57bec3c6e0 100644 --- a/bacula/src/qt-console/restore/restore.cpp +++ b/bacula/src/qt-console/restore/restore.cpp @@ -61,6 +61,13 @@ restorePage::restorePage() connect(unmarkButton, SIGNAL(pressed()), this, SLOT(unmarkButtonPushed())); connect(okButton, SIGNAL(pressed()), this, SLOT(okButtonPushed())); connect(cancelButton, SIGNAL(pressed()), this, SLOT(cancelButtonPushed())); + + fileWidget->setContextMenuPolicy(Qt::ActionsContextMenu); + fileWidget->addAction(actionMark); + fileWidget->addAction(actionUnMark); + connect(actionMark, SIGNAL(triggered()), this, SLOT(markButtonPushed())); + connect(actionUnMark, SIGNAL(triggered()), this, SLOT(unmarkButtonPushed())); + setFont(m_console->get_font()); m_console->displayToPrompt(); diff --git a/bacula/src/qt-console/restore/restore.ui b/bacula/src/qt-console/restore/restore.ui index a20984e33d..0429324889 100644 --- a/bacula/src/qt-console/restore/restore.ui +++ b/bacula/src/qt-console/restore/restore.ui @@ -239,7 +239,7 @@ Up - :images/up.png + :/images/up.png @@ -263,7 +263,7 @@ Mark - :images/mark.png + :/images/check.png @@ -287,7 +287,7 @@ Unmark - :images/unmark.png + :/images/unchecked.png @@ -438,7 +438,25 @@ + + + :/images/check.png + + + Mark + + + + + :/images/unchecked.png + + + UnMark + + - + + + diff --git a/bacula/src/qt-console/run/run.cpp b/bacula/src/qt-console/run/run.cpp index 4ea8d58233..3f397a72d2 100644 --- a/bacula/src/qt-console/run/run.cpp +++ b/bacula/src/qt-console/run/run.cpp @@ -48,7 +48,7 @@ runPage::runPage() pgInitialize(); setupUi(this); QTreeWidgetItem* thisitem = mainWin->getFromHash(this); - thisitem->setIcon(0,QIcon(QString::fromUtf8(":images/emblem-system.svg"))); + thisitem->setIcon(0,QIcon(QString::fromUtf8(":images/run.png"))); m_console->notify(false); m_console->beginNewCommand(); -- 2.39.5