Commit 5b821a29 authored by Robert Lancaster's avatar Robert Lancaster Committed by Jasem Mutlaq

Fixes icons on systems that cannot load icons from system

 themes using the fromTheme method like OS X, Windows, and some Linux Distros.
  If there is no system theme, it tries to set the theme to one of the bundled
 themes if possible, but also adds the fallback method for loading icons
 without a theme to each icon if that doesn't work.   Added an icons directory
 to keep the theme icons and toolbar icons separate from the other data.
 Included two bundled custom themes, based on breeze and oxygen.  Also fixed
 the call to the "geographic" icon and the "edit indi profile" icon since they
 may have been referencing the wrong icons.

CCMAIL:kstars-devel@kde.org
parent b10766db
......@@ -154,7 +154,7 @@ void ImageViewer::init(QString caption, QString capText)
QPushButton *invertB = new QPushButton(i18n("Invert colors"));
invertB->setToolTip(i18n("Reverse colors of the image. This is useful to enhance contrast at times. This affects only the display and not the saving."));
QPushButton *saveB = new QPushButton(QIcon::fromTheme("document-save"), i18n("Save"));
QPushButton *saveB = new QPushButton(QIcon::fromTheme("document-save", QIcon(":/icons/breeze/default/document-save.png")), i18n("Save"));
saveB->setToolTip(i18n("Save the image to disk"));
buttonBox->addButton(invertB, QDialogButtonBox::ActionRole);
......
......@@ -63,7 +63,7 @@ install(FILES
wzstars.png wzgeo.png wzscope.png wzdownload.png chart.colors
classic.colors moonless-night.colors night.colors
tips TZrules.dat valaav.txt Interesting.dat PlanetFacts.dat
advinterface.dat satellites.dat histogram.png go-nw.png go-ne.png go-sw.png go-se.png glossary.xml defaultflag.gif
advinterface.dat satellites.dat glossary.xml defaultflag.gif
DESTINATION ${KDE_INSTALL_DATADIR}/kstars
)
......
<RCC>
<qresource prefix="/icons">
<file>catalog.png</file>
<file>cbound.png</file>
<file>clines.png</file>
<file>cnames.png</file>
<file>colors.png</file>
<file>constellationart.png</file>
<file>deepsky.png</file>
<file>ekos_align.png</file>
<file>ekos_ccd.png</file>
<file>ekos_focus.png</file>
<file>ekos_guide.png</file>
<file>ekos_mount.png</file>
<file>ekos_scheduler.png</file>
<file>ekos_setup.png</file>
<file>ekos.png</file>
<file>fitsviewer.png</file>
<file>flag.png</file>
<file>fov.png</file>
<file>grid.png</file>
<file>guides.png</file>
<file>hgrid.png</file>
<file>horizon.png</file>
<file>indi.png</file>
<file>kstars.png</file>
<file>mw.png</file>
<file>planets.png</file>
<file>satellites.png</file>
<file>solarsystem.png</file>
<file>stars.png</file>
<file>supernovae.png</file>
<file>xplanet.png</file>
<file>advanced.png</file>
<qresource prefix="/">
<file>icons/catalog.png</file>
<file>icons/cbound.png</file>
<file>icons/clines.png</file>
<file>icons/cnames.png</file>
<file>icons/colors.png</file>
<file>icons/constellationart.png</file>
<file>icons/deepsky.png</file>
<file>icons/ekos_align.png</file>
<file>icons/ekos_ccd.png</file>
<file>icons/ekos_focus.png</file>
<file>icons/ekos_guide.png</file>
<file>icons/ekos_mount.png</file>
<file>icons/ekos_scheduler.png</file>
<file>icons/ekos_setup.png</file>
<file>icons/ekos.png</file>
<file>icons/fitsviewer.png</file>
<file>icons/flag.png</file>
<file>icons/fov.png</file>
<file>icons/grid.png</file>
<file>icons/guides.png</file>
<file>icons/hgrid.png</file>
<file>icons/horizon.png</file>
<file>icons/indi.png</file>
<file>icons/mw.png</file>
<file>icons/planets.png</file>
<file>icons/satellites.png</file>
<file>icons/solarsystem.png</file>
<file>icons/stars.png</file>
<file>icons/supernovae.png</file>
<file>icons/xplanet.png</file>
<file>icons/advanced.png</file>
<file>icons/breeze/index.theme</file>
<file>icons/breeze/default/accessories-calculator.svg</file>
<file>icons/breeze/default/application-exit.svg</file>
<file>icons/breeze/default/applications-internet.svg</file>
<file>icons/breeze/default/arrow-down.svg</file>
<file>icons/breeze/default/arrow-right.svg</file>
<file>icons/breeze/default/arrow-right-double.svg</file>
<file>icons/breeze/default/arrow-left.svg</file>
<file>icons/breeze/default/arrow-left-double.svg</file>
<file>icons/breeze/default/arrow-up.svg</file>
<file>icons/breeze/default/chronometer.svg</file>
<file>icons/breeze/default/clock.svg</file>
<file>icons/breeze/default/computer.svg</file>
<file>icons/breeze/default/crosshairs.svg</file>
<file>icons/breeze/default/dialog-cancel.svg</file>
<file>icons/breeze/default/dialog-ok-apply.svg</file>
<file>icons/breeze/default/document-edit.svg</file>
<file>icons/breeze/default/document-encrypt.svg</file>
<file>icons/breeze/default/document-export.svg</file>
<file>icons/breeze/default/document-new.svg</file>
<file>icons/breeze/default/document-open-folder.svg</file>
<file>icons/breeze/default/document-open.svg</file>
<file>icons/breeze/default/document-print.svg</file>
<file>icons/breeze/default/document-properties.svg</file>
<file>icons/breeze/default/document-save-as.svg</file>
<file>icons/breeze/default/document-save.svg</file>
<file>icons/breeze/default/download.svg</file>
<file>icons/breeze/default/edit-clear.svg</file>
<file>icons/breeze/default/edit-copy.svg</file>
<file>icons/breeze/default/edit-delete.svg</file>
<file>icons/breeze/default/edit-find.svg</file>
<file>icons/breeze/default/edit-undo.svg</file>
<file>icons/breeze/default/edit-redo.svg</file>
<file>icons/breeze/default/favorites.svg</file>
<file>icons/breeze/default/go-down.svg</file>
<file>icons/breeze/default/go-next.svg</file>
<file>icons/breeze/default/go-previous.svg</file>
<file>icons/breeze/default/go-up.svg</file>
<file>icons/breeze/default/help-hint.svg</file>
<file>icons/breeze/default/list-add.svg</file>
<file>icons/breeze/default/list-remove.svg</file>
<file>icons/breeze/default/media-playback-pause.svg</file>
<file>icons/breeze/default/media-playback-start.svg</file>
<file>icons/breeze/default/media-playback-stop.svg</file>
<file>icons/breeze/default/media-skip-backward.svg</file>
<file>icons/breeze/default/media-skip-forward.svg</file>
<file>icons/breeze/default/modem.svg</file>
<file>icons/breeze/default/network-connect.svg</file>
<file>icons/breeze/default/network-disconnect.svg</file>
<file>icons/breeze/default/network-server.svg</file>
<file>icons/breeze/default/object-flip-horizontal.svg</file>
<file>icons/breeze/default/object-flip-vertical.svg</file>
<file>icons/breeze/default/object-locked.svg</file>
<file>icons/breeze/default/object-rotate-left.svg</file>
<file>icons/breeze/default/object-rotate-right.svg</file>
<file>icons/breeze/default/process-stop.svg</file>
<file>icons/breeze/default/run-build.svg</file>
<file>icons/breeze/default/security-high.svg</file>
<file>icons/breeze/default/security-low.svg</file>
<file>icons/breeze/default/security-medium.svg</file>
<file>icons/breeze/default/snap-orthogonal.svg</file>
<file>icons/breeze/default/svn-update.svg</file>
<file>icons/breeze/default/system-reboot.svg</file>
<file>icons/breeze/default/system-run.svg</file>
<file>icons/breeze/default/tools-wizard.svg</file>
<file>icons/breeze/default/transform-move.svg</file>
<file>icons/breeze/default/view-fullscreen.svg</file>
<file>icons/breeze/default/view-history.svg</file>
<file>icons/breeze/default/view-preview.svg</file>
<file>icons/breeze/default/view-refresh.svg</file>
<file>icons/breeze/default/view-restore.svg</file>
<file>icons/breeze/default/view-statistics.svg</file>
<file>icons/breeze/default/window-close.svg</file>
<file>icons/breeze/default/zoom-draw.svg</file>
<file>icons/breeze/default/zoom-fit-best.svg</file>
<file>icons/breeze/default/zoom-in.svg</file>
<file>icons/breeze/default/zoom-original.svg</file>
<file>icons/breeze/default/zoom-out.svg</file>
<file>icons/breeze/default/kstars_grid.svg</file>
<file>icons/breeze/default/kstars_guides.svg</file>
<file>icons/breeze/default/kstars_advanced.svg</file>
<file>icons/breeze/default/kstars_hgrid.svg</file>
<file>icons/breeze/default/kstars_catalog.svg</file>
<file>icons/breeze/default/kstars_horizon.svg</file>
<file>icons/breeze/default/kstars_cbound.svg</file>
<file>icons/breeze/default/kstars_indi.svg</file>
<file>icons/breeze/default/kstars_clines.svg</file>
<file>icons/breeze/default/kstars_mw.svg</file>
<file>icons/breeze/default/kstars_cnames.svg</file>
<file>icons/breeze/default/kstars_planets.svg</file>
<file>icons/breeze/default/kstars_colors.svg</file>
<file>icons/breeze/default/kstars_satellites.svg</file>
<file>icons/breeze/default/kstars_constellationart.svg</file>
<file>icons/breeze/default/kstars_solarsystem.svg</file>
<file>icons/breeze/default/kstars_deepsky.svg</file>
<file>icons/breeze/default/kstars_stars.svg</file>
<file>icons/breeze/default/kstars_ekos.svg</file>
<file>icons/breeze/default/kstars_supernovae.svg</file>
<file>icons/breeze/default/kstars_fitsviewer.svg</file>
<file>icons/breeze/default/kstars_xplanet.svg</file>
<file>icons/breeze/default/kstars_flag.svg</file>
</qresource>
<qresource prefix="/kconfig">
<file>kstars.knsrc</file>
......
......@@ -68,9 +68,9 @@ LocationDialog::LocationDialog( QWidget* parent ) :
ld->DSTRuleBox->addItem( key );
}
ld->AddCityButton->setIcon(QIcon::fromTheme("list-add"));
ld->RemoveButton->setIcon(QIcon::fromTheme("list-remove"));
ld->UpdateButton->setIcon(QIcon::fromTheme("svn-update"));
ld->AddCityButton->setIcon(QIcon::fromTheme("list-add", QIcon(":/icons/breeze/default/list-add.png")));
ld->RemoveButton->setIcon(QIcon::fromTheme("list-remove", QIcon(":/icons/breeze/default/list-remove.png")));
ld->UpdateButton->setIcon(QIcon::fromTheme("svn-update", QIcon(":/icons/breeze/default/svn-update.png")));
connect( ld->CityFilter, SIGNAL( textChanged( const QString & ) ), this, SLOT( enqueueFilterCity() ) );
connect( ld->ProvinceFilter, SIGNAL( textChanged( const QString & ) ), this, SLOT( enqueueFilterCity() ) );
......
......@@ -114,8 +114,8 @@ Align::Align()
else
nothingR->setChecked(true);
syncBoxesB->setIcon(QIcon::fromTheme("edit-copy"));
clearBoxesB->setIcon(QIcon::fromTheme("edit-clear"));
syncBoxesB->setIcon(QIcon::fromTheme("edit-copy", QIcon(":/icons/breeze/default/edit-copy.png")));
clearBoxesB->setIcon(QIcon::fromTheme("edit-clear", QIcon(":/icons/breeze/default/edit-clear.png")));
raBox->setDegType(false); //RA box should be HMS-style
......
......@@ -119,8 +119,8 @@ Capture::Capture()
connect(startB, SIGNAL(clicked()), this, SLOT(toggleSequence()));
connect(pauseB, SIGNAL(clicked()), this, SLOT(pause()));
startB->setIcon(QIcon::fromTheme("media-playback-start"));
pauseB->setIcon(QIcon::fromTheme("media-playback-pause"));
startB->setIcon(QIcon::fromTheme("media-playback-start", QIcon(":/icons/breeze/default/media-playback-start.png") ));
pauseB->setIcon(QIcon::fromTheme("media-playback-pause", QIcon(":/icons/breeze/default/media-playback-pause.png") ));
connect(binXIN, SIGNAL(valueChanged(int)), binYIN, SLOT(setValue(int)));
......@@ -151,17 +151,17 @@ Capture::Capture()
connect(resetFrameB, SIGNAL(clicked()), this, SLOT(resetFrame()));
connect(calibrationB, SIGNAL(clicked()), this, SLOT(openCalibrationDialog()));
addToQueueB->setIcon(QIcon::fromTheme("list-add"));
removeFromQueueB->setIcon(QIcon::fromTheme("list-remove"));
queueUpB->setIcon(QIcon::fromTheme("go-up"));
queueDownB->setIcon(QIcon::fromTheme("go-down"));
selectFITSDirB->setIcon(QIcon::fromTheme("document-open-folder"));
queueLoadB->setIcon(QIcon::fromTheme("document-open"));
queueSaveB->setIcon(QIcon::fromTheme("document-save"));
queueSaveAsB->setIcon(QIcon::fromTheme("document-save-as"));
resetB->setIcon(QIcon::fromTheme("system-reboot"));
resetFrameB->setIcon(QIcon::fromTheme("view-refresh"));
calibrationB->setIcon(QIcon::fromTheme("run-build"));
addToQueueB->setIcon(QIcon::fromTheme("list-add", QIcon(":/icons/breeze/default/list-add.png") ));
removeFromQueueB->setIcon(QIcon::fromTheme("list-remove", QIcon(":/icons/breeze/default/list-remove.png") ));
queueUpB->setIcon(QIcon::fromTheme("go-up", QIcon(":/icons/breeze/default/go-up.png") ));
queueDownB->setIcon(QIcon::fromTheme("go-down", QIcon(":/icons/go-down.png") ));
selectFITSDirB->setIcon(QIcon::fromTheme("document-open-folder", QIcon(":/icons/breeze/default/document-open-folder.png") ));
queueLoadB->setIcon(QIcon::fromTheme("document-open", QIcon(":/icons/breeze/default/document-open.png") ));
queueSaveB->setIcon(QIcon::fromTheme("document-save", QIcon(":/icons/breeze/default/document-save.png") ));
queueSaveAsB->setIcon(QIcon::fromTheme("document-save-as", QIcon(":/icons/breeze/default/document-save-as.png") ));
resetB->setIcon(QIcon::fromTheme("system-reboot", QIcon(":/icons/breeze/default/system-reboot.png") ));
resetFrameB->setIcon(QIcon::fromTheme("view-refresh", QIcon(":/icons/breeze/default/view-refresh.png") ));
calibrationB->setIcon(QIcon::fromTheme("run-build", QIcon(":/icons/breeze/default/run-build.png") ));
addToQueueB->setToolTip(i18n("Add job to sequence queue"));
removeFromQueueB->setToolTip(i18n("Remove job from sequence queue"));
......@@ -266,7 +266,7 @@ void Capture::pause()
appendLogText(i18n("Sequence shall be paused after current exposure is complete."));
pauseB->setEnabled(false);
startB->setIcon(QIcon::fromTheme("media-playback-start"));
startB->setIcon(QIcon::fromTheme("media-playback-start", QIcon(":/icons/breeze/default/media-playback-start.png") ));
startB->setToolTip(i18n("Resume Sequence"));
}
......@@ -274,7 +274,7 @@ void Capture::toggleSequence()
{
if (state == CAPTURE_PAUSED)
{
startB->setIcon(QIcon::fromTheme("media-playback-stop"));
startB->setIcon(QIcon::fromTheme("media-playback-stop", QIcon(":/icons/breeze/default/media-playback-stop.png") ));
startB->setToolTip(i18n("Stop Sequence"));
pauseB->setEnabled(true);
......@@ -373,7 +373,7 @@ void Capture::start()
state = CAPTURE_PROGRESS;
emit newStatus(Ekos::CAPTURE_PROGRESS);
startB->setIcon(QIcon::fromTheme("media-playback-stop"));
startB->setIcon(QIcon::fromTheme("media-playback-stop", QIcon(":/icons/breeze/default/media-playback-stop.png") ));
startB->setToolTip(i18n("Stop Sequence"));
pauseB->setEnabled(true);
......@@ -442,7 +442,7 @@ void Capture::stop(bool abort)
if (abort)
{
startB->setIcon(QIcon::fromTheme("media-playback-start"));
startB->setIcon(QIcon::fromTheme("media-playback-start", QIcon(":/icons/breeze/default/media-playback-start.png") ));
startB->setToolTip(i18n("Start Sequence"));
pauseB->setEnabled(false);
}
......@@ -2604,7 +2604,7 @@ void Capture::editJob(QModelIndex i)
appendLogText(i18n("Editing job #%1...", i.row()+1));
addToQueueB->setIcon(QIcon::fromTheme("dialog-ok-apply"));
addToQueueB->setIcon(QIcon::fromTheme("dialog-ok-apply", QIcon(":/icons/breeze/default/dialog-ok-apply.png") ));
addToQueueB->setToolTip(i18n("Apply job changes."));
removeFromQueueB->setToolTip(i18n("Cancel job changes."));
......@@ -2618,7 +2618,7 @@ void Capture::resetJobEdit()
appendLogText(i18n("Editing job canceled."));
jobUnderEdit = false;
addToQueueB->setIcon(QIcon::fromTheme("list-add"));
addToQueueB->setIcon(QIcon::fromTheme("list-add", QIcon(":/icons/breeze/default/list-add.png") ));
addToQueueB->setToolTip(i18n("Add job to sequence queue"));
removeFromQueueB->setToolTip(i18n("Remove job from sequence queue"));
......
......@@ -127,9 +127,9 @@ EkosManager::EkosManager(QWidget *parent) : QDialog(parent)
connect(profileCombo, SIGNAL(activated(QString)), this, SLOT(saveDefaultProfile(QString)));
// Set Profile icons
addProfileB->setIcon(QIcon::fromTheme("list-add"));
editProfileB->setIcon(QIcon::fromTheme("edit-entry"));
deleteProfileB->setIcon(QIcon::fromTheme("list-remove"));
addProfileB->setIcon(QIcon::fromTheme("list-add", QIcon(":/icons/breeze/default/list-add.png")));
editProfileB->setIcon(QIcon::fromTheme("document-edit", QIcon(":/icons/indi.png")));
deleteProfileB->setIcon(QIcon::fromTheme("list-remove", QIcon(":/icons/breeze/default/list-remove.png")));
// Load all drivers
loadDrivers();
......
......@@ -220,7 +220,7 @@ Mosaic::Mosaic(Scheduler *scheduler)
scene.addItem(mosaicTile);
mosaicView->setScene(&scene);
selectJobsDirB->setIcon(QIcon::fromTheme("document-open-folder"));
selectJobsDirB->setIcon(QIcon::fromTheme("document-open-folder", QIcon(":/icons/breeze/default/document-open-folder.png")));
//mosaicView->setResizeAnchor(QGraphicsView::AnchorViewCenter);
......
......@@ -42,43 +42,21 @@ Mount::Mount()
currentTelescope = NULL;
stopB->setIcon(QIcon::fromTheme("process-stop"));
northB->setIcon(QIcon::fromTheme("go-up"));
westB->setIcon(QIcon::fromTheme("go-previous"));
eastB->setIcon(QIcon::fromTheme("go-next"));
southB->setIcon(QIcon::fromTheme("go-down"));
stopB->setIcon(QIcon::fromTheme("process-stop", QIcon(":/icons/breeze/default/process-stop.png")));
northB->setIcon(QIcon::fromTheme("go-up", QIcon(":/icons/breeze/default/go-up.png")));
westB->setIcon(QIcon::fromTheme("go-previous", QIcon(":/icons/breeze/default/go-previous.png")));
eastB->setIcon(QIcon::fromTheme("go-next", QIcon(":/icons/breeze/default/go-next.png")));
southB->setIcon(QIcon::fromTheme("go-down", QIcon(":/icons/breeze/default/go-down.png")));
abortDispatch = -1;
minAltLimit->setValue(Options::minimumAltLimit());
maxAltLimit->setValue(Options::maximumAltLimit());
QFile tempFile;
if (KSUtils::openDataFile( tempFile, "go-nw.png" ) )
{
northwestB->setIcon(QIcon(tempFile.fileName()));
tempFile.close();
}
if (KSUtils::openDataFile( tempFile, "go-ne.png" ) )
{
northeastB->setIcon(QIcon(tempFile.fileName()));
tempFile.close();
}
if (KSUtils::openDataFile( tempFile, "go-sw.png" ) )
{
southwestB->setIcon(QIcon(tempFile.fileName()));
tempFile.close();
}
if (KSUtils::openDataFile( tempFile, "go-se.png" ) )
{
southeastB->setIcon(QIcon(tempFile.fileName()));
tempFile.close();
}
northwestB->setIcon(QIcon(":/icons/go-nw.png"));
northeastB->setIcon(QIcon(":/icons/go-nw.png"));
southwestB->setIcon(QIcon(":/icons/go-sw.png"));
southeastB->setIcon(QIcon(":/icons/go-se.png"));
connect(northB, SIGNAL(pressed()), this, SLOT(move()));
connect(northB, SIGNAL(released()), this, SLOT(stop()));
......
......@@ -31,7 +31,7 @@ OpsEkos::OpsEkos()
//Get a pointer to the KConfigDialog
m_ConfigDialog = KConfigDialog::exists( "settings" );
selectPHD2B->setIcon(QIcon::fromTheme("document-open"));
selectPHD2B->setIcon(QIcon::fromTheme("document-open", QIcon(":/icons/breeze/default/document-open.png")));
connect( m_ConfigDialog->button(QDialogButtonBox::Apply), SIGNAL( clicked() ), SLOT( slotApply() ) );
connect( m_ConfigDialog->button(QDialogButtonBox::Ok), SIGNAL( clicked() ), SLOT( slotApply() ) );
......
......@@ -129,7 +129,7 @@ Scheduler::Scheduler()
moon = dynamic_cast<KSMoon*> (KStarsData::Instance()->skyComposite()->findByName("Moon"));
sleepLabel->setPixmap(QIcon::fromTheme("chronometer").pixmap(QSize(32,32)));
sleepLabel->setPixmap(QIcon::fromTheme("chronometer", QIcon(":/icons/breeze/default/chronometer.png")).pixmap(QSize(32,32)));
sleepLabel->hide();
schedulerTimer.setInterval(UPDATE_PERIOD_MS);
......@@ -146,26 +146,26 @@ Scheduler::Scheduler()
raBox->setDegType(false); //RA box should be HMS-style
addToQueueB->setIcon(QIcon::fromTheme("list-add"));
addToQueueB->setIcon(QIcon::fromTheme("list-add", QIcon(":/icons/breeze/default/list-add.png")));
addToQueueB->setToolTip(i18n("Add observation job to list."));
removeFromQueueB->setIcon(QIcon::fromTheme("list-remove"));
removeFromQueueB->setIcon(QIcon::fromTheme("list-remove", QIcon(":/icons/breeze/default/list-remove.png")));
removeFromQueueB->setToolTip(i18n("Remove observation job from list."));
evaluateOnlyB->setIcon(QIcon::fromTheme("tools-wizard"));
mosaicB->setIcon(QIcon::fromTheme("zoom-draw"));
evaluateOnlyB->setIcon(QIcon::fromTheme("tools-wizard", QIcon(":/icons/breeze/default/tools-wizard.png")));
mosaicB->setIcon(QIcon::fromTheme("zoom-draw", QIcon(":/icons/breeze/default/zoom-draw.png")));
queueSaveAsB->setIcon(QIcon::fromTheme("document-save-as"));
queueSaveB->setIcon(QIcon::fromTheme("document-save"));
queueLoadB->setIcon(QIcon::fromTheme("document-open"));
queueSaveAsB->setIcon(QIcon::fromTheme("document-save-as", QIcon(":/icons/breeze/default/document-save-as.png")));
queueSaveB->setIcon(QIcon::fromTheme("document-save", QIcon(":/icons/breeze/default/document-save.png")));
queueLoadB->setIcon(QIcon::fromTheme("document-open", QIcon(":/icons/breeze/default/document-open.png")));
loadSequenceB->setIcon(QIcon::fromTheme("document-open"));
selectStartupScriptB->setIcon(QIcon::fromTheme("document-open"));
selectShutdownScriptB->setIcon(QIcon::fromTheme("document-open"));
selectFITSB->setIcon(QIcon::fromTheme("document-open"));
loadSequenceB->setIcon(QIcon::fromTheme("document-open", QIcon(":/icons/breeze/default/document-open.png")));
selectStartupScriptB->setIcon(QIcon::fromTheme("document-open", QIcon(":/icons/breeze/default/document-open.png")));
selectShutdownScriptB->setIcon(QIcon::fromTheme("document-open", QIcon(":/icons/breeze/default/document-open.png")));
selectFITSB->setIcon(QIcon::fromTheme("document-open", QIcon(":/icons/breeze/default/document-open.png")));
startupB->setIcon(QIcon::fromTheme("media-playback-start"));
shutdownB->setIcon(QIcon::fromTheme("media-playback-start"));
startupB->setIcon(QIcon::fromTheme("media-playback-start", QIcon(":/icons/breeze/default/media-playback-start.png")));
shutdownB->setIcon(QIcon::fromTheme("media-playback-start", QIcon(":/icons/breeze/default/media-playback-start.png")));
connect(startupB, SIGNAL(clicked()), this, SLOT(runStartupProcedure()));
connect(shutdownB, SIGNAL(clicked()), this, SLOT(runShutdownProcedure()));
......@@ -183,8 +183,8 @@ Scheduler::Scheduler()
connect(queueTable, SIGNAL(clicked(QModelIndex)), this, SLOT(loadJob(QModelIndex)));
connect(queueTable, SIGNAL(doubleClicked(QModelIndex)), this, SLOT(resetJobState(QModelIndex)));
startB->setIcon(QIcon::fromTheme("media-playback-start"));
pauseB->setIcon(QIcon::fromTheme("media-playback-pause"));
startB->setIcon(QIcon::fromTheme("media-playback-start", QIcon(":/icons/breeze/default/media-playback-start.png")));
pauseB->setIcon(QIcon::fromTheme("media-playback-pause", QIcon(":/icons/breeze/default/media-playback-pause.png")));
connect(startB,SIGNAL(clicked()),this,SLOT(toggleScheduler()));
connect(pauseB,SIGNAL(clicked()),this,SLOT(pause()));
......@@ -732,7 +732,7 @@ void Scheduler::loadJob(QModelIndex i)
appendLogText(i18n("Editing job #%1...", i.row()+1));
addToQueueB->setIcon(QIcon::fromTheme("edit-undo"));
addToQueueB->setIcon(QIcon::fromTheme("edit-undo", QIcon(":/icons/breeze/default/edit-undo.png")));
addToQueueB->setStyleSheet("background-color:orange;}");
addToQueueB->setEnabled(true);
startB->setEnabled(false);
......@@ -755,7 +755,7 @@ void Scheduler::resetJobEdit()
watchJobChanges(false);
addToQueueB->setIcon(QIcon::fromTheme("list-add"));
addToQueueB->setIcon(QIcon::fromTheme("list-add", QIcon(":/icons/breeze/default/list-add.png")));
addToQueueB->setStyleSheet(QString());
addToQueueB->setToolTip(i18n("Add observation job to list."));
queueTable->clearSelection();
......@@ -918,7 +918,7 @@ void Scheduler::stop()
sleepLabel->hide();
pi->stopAnimation();
startB->setIcon(QIcon::fromTheme("media-playback-start"));
startB->setIcon(QIcon::fromTheme("media-playback-start", QIcon(":/icons/breeze/default/media-playback-start.png")));
startB->setToolTip(i18n("Start Scheduler"));
pauseB->setEnabled(false);
//startB->setText("Start Scheduler");
......@@ -939,7 +939,7 @@ void Scheduler::start()
state = SCHEDULER_RUNNIG;
appendLogText(i18n("Scheduler resumed."));
startB->setIcon(QIcon::fromTheme("media-playback-stop"));
startB->setIcon(QIcon::fromTheme("media-playback-stop", QIcon(":/icons/breeze/default/media-playback-stop.png")));
startB->setToolTip(i18n("Stop Scheduler"));
return;
}
......@@ -966,7 +966,7 @@ void Scheduler::start()
sleepLabel->hide();
//startB->setText("Stop Scheduler");
startB->setIcon(QIcon::fromTheme("media-playback-stop"));
startB->setIcon(QIcon::fromTheme("media-playback-stop", QIcon(":/icons/breeze/default/media-playback-stop.png")));
startB->setToolTip(i18n("Stop Scheduler"));
pauseB->setEnabled(true);
......@@ -1006,7 +1006,7 @@ void Scheduler::pause()
appendLogText(i18n("Scheduler paused."));
pauseB->setEnabled(false);
startB->setIcon(QIcon::fromTheme("media-playback-start"));
startB->setIcon(QIcon::fromTheme("media-playback-start", QIcon(":/icons/breeze/default/media-playback-start.png")));
startB->setToolTip(i18n("Resume Scheduler"));
}
......@@ -1615,19 +1615,19 @@ void Scheduler::checkWeather()
qDebug() << "Scheduler: " << statusString;
if (weatherStatus == IPS_OK)
weatherLabel->setPixmap(QIcon::fromTheme("security-high").pixmap(QSize(32,32)));
weatherLabel->setPixmap(QIcon::fromTheme("security-high", QIcon(":/icons/breeze/default/security-high.png")).pixmap(QSize(32,32)));
else if (weatherStatus == IPS_BUSY)