From: Dirk H Bartley Date: Wed, 30 May 2007 20:39:12 +0000 (+0000) Subject: A little bit of playing around with icons. Added context sensitve menu to the X-Git-Tag: Release-7.0.0~6201 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=aaca3d0300c30d6dfed2fb5d7b661191fb1633af;p=bacula%2Fbacula 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 --- diff --git a/bacula/src/qt-console/images/joblog.png b/bacula/src/qt-console/images/joblog.png new file mode 100644 index 0000000000..6728b1dca1 Binary files /dev/null and b/bacula/src/qt-console/images/joblog.png differ 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();