diff options
-rw-r--r-- | desktop-editor/global.h | 3 | ||||
-rw-r--r-- | lumina-desktop/desktop-plugins/desktopview/DesktopViewPlugin.cpp | 11 | ||||
-rw-r--r-- | lumina-desktop/desktop-plugins/desktopview/DesktopViewPlugin.h | 1 | ||||
-rw-r--r-- | lumina-fileinfo/dialog.cpp (renamed from desktop-editor/dialog.cpp) | 6 | ||||
-rw-r--r-- | lumina-fileinfo/dialog.h (renamed from desktop-editor/dialog.h) | 0 | ||||
-rw-r--r-- | lumina-fileinfo/dialog.ui (renamed from desktop-editor/dialog.ui) | 0 | ||||
-rw-r--r-- | lumina-fileinfo/fileinfo-app.template (renamed from desktop-editor/desktop-app.template) | 0 | ||||
-rw-r--r-- | lumina-fileinfo/fileinfo-link.template (renamed from desktop-editor/desktop-link.template) | 0 | ||||
-rw-r--r-- | lumina-fileinfo/lumina-fileinfo.desktop | 10 | ||||
-rw-r--r-- | lumina-fileinfo/lumina-fileinfo.pro (renamed from desktop-editor/desktop-editor.pro) | 10 | ||||
-rw-r--r-- | lumina-fileinfo/main.cpp (renamed from desktop-editor/main.cpp) | 2 | ||||
-rw-r--r-- | lumina.pro | 3 |
12 files changed, 35 insertions, 11 deletions
diff --git a/desktop-editor/global.h b/desktop-editor/global.h deleted file mode 100644 index f93e2d08..00000000 --- a/desktop-editor/global.h +++ /dev/null @@ -1,3 +0,0 @@ -#ifndef PREFIX - #define PREFIX QString("/usr/local") -#endif diff --git a/lumina-desktop/desktop-plugins/desktopview/DesktopViewPlugin.cpp b/lumina-desktop/desktop-plugins/desktopview/DesktopViewPlugin.cpp index 0aa4a3de..5526f267 100644 --- a/lumina-desktop/desktop-plugins/desktopview/DesktopViewPlugin.cpp +++ b/lumina-desktop/desktop-plugins/desktopview/DesktopViewPlugin.cpp @@ -36,6 +36,8 @@ DesktopViewPlugin::DesktopViewPlugin(QWidget* parent, QString ID) : LDPlugin(par menu->addAction( LXDG::findIcon("zoom-out",""), tr("Decrease Icons"), this, SLOT(decreaseIconSize()) ); menu->addSeparator(); menu->addAction( LXDG::findIcon("edit-delete",""), tr("Delete"), this, SLOT(deleteItems()) ); + menu->addSeparator(); + menu->addAction( LXDG::findIcon("system-search",""), tr("Properties"), this, SLOT(displayProperties()) ); this->layout()->addWidget(list); this->setInitialSize(600,600); watcher = new QFileSystemWatcher(this); @@ -157,4 +159,11 @@ void DesktopViewPlugin::updateContents(){ } list->addItem(it); } -}
\ No newline at end of file +} + +void DesktopViewPlugin::displayProperties(){ + QList<QListWidgetItem*> sel = list->selectedItems(); + for(int i=0; i<sel.length(); i++){ + LSession::LaunchApplication("lumina-fileinfo \""+sel[i]->whatsThis()); + } +} diff --git a/lumina-desktop/desktop-plugins/desktopview/DesktopViewPlugin.h b/lumina-desktop/desktop-plugins/desktopview/DesktopViewPlugin.h index 61e1caf9..86240dc8 100644 --- a/lumina-desktop/desktop-plugins/desktopview/DesktopViewPlugin.h +++ b/lumina-desktop/desktop-plugins/desktopview/DesktopViewPlugin.h @@ -37,6 +37,7 @@ private slots: void increaseIconSize(); void decreaseIconSize(); void updateContents(); + void displayProperties(); public slots: diff --git a/desktop-editor/dialog.cpp b/lumina-fileinfo/dialog.cpp index 359257d6..bcb3a14d 100644 --- a/desktop-editor/dialog.cpp +++ b/lumina-fileinfo/dialog.cpp @@ -68,8 +68,8 @@ void Dialog::LoadDesktopFile(QString input) //if proposed file does not exist, than we will create one based on the templates //TODO: have a config directory to store templates if (!QFile::exists(input)) { - if (desktopType=="link") { QFile::copy("./desktop-link.template", desktopFileName);} - else { QFile::copy("./desktop-app.template", desktopFileName);} + if (desktopType=="link") { QFile::copy("./fileinfo-link.template", desktopFileName);} + else { QFile::copy("./fileinfo-app.template", desktopFileName);} } //use the standard LXDG object and load the desktop file @@ -205,8 +205,6 @@ void Dialog::on_pbApply_clicked() file.close(); //hack required to update the icon on the desktop - //maybe the solution would be to have a QFileSystemWatcher (in AppLauncherPlugin.cpp) - //on files instead of ~/Desktop QTemporaryFile tempFile ; tempFile.setAutoRemove(false); tempFile.open(); diff --git a/desktop-editor/dialog.h b/lumina-fileinfo/dialog.h index e58f0938..e58f0938 100644 --- a/desktop-editor/dialog.h +++ b/lumina-fileinfo/dialog.h diff --git a/desktop-editor/dialog.ui b/lumina-fileinfo/dialog.ui index 8cca25d4..8cca25d4 100644 --- a/desktop-editor/dialog.ui +++ b/lumina-fileinfo/dialog.ui diff --git a/desktop-editor/desktop-app.template b/lumina-fileinfo/fileinfo-app.template index 8519d3a1..8519d3a1 100644 --- a/desktop-editor/desktop-app.template +++ b/lumina-fileinfo/fileinfo-app.template diff --git a/desktop-editor/desktop-link.template b/lumina-fileinfo/fileinfo-link.template index 4a0b7830..4a0b7830 100644 --- a/desktop-editor/desktop-link.template +++ b/lumina-fileinfo/fileinfo-link.template diff --git a/lumina-fileinfo/lumina-fileinfo.desktop b/lumina-fileinfo/lumina-fileinfo.desktop new file mode 100644 index 00000000..d5b5ddf9 --- /dev/null +++ b/lumina-fileinfo/lumina-fileinfo.desktop @@ -0,0 +1,10 @@ +[Desktop Entry] +Exec=/home/wi/nas/github/lumina/desktop-editor/desktop-editor +Icon=/usr/local/share/pixmaps/Lumina-DE.png +Terminal=false +Type=Application +StartupNotify=true +Categories=System; +Name=Lumina Desktop Information +Comment=View information about the Lumina Desktop Environment + diff --git a/desktop-editor/desktop-editor.pro b/lumina-fileinfo/lumina-fileinfo.pro index dc3eadf2..9524f9ef 100644 --- a/desktop-editor/desktop-editor.pro +++ b/lumina-fileinfo/lumina-fileinfo.pro @@ -8,12 +8,13 @@ QT += core gui greaterThan(QT_MAJOR_VERSION, 4): QT += widgets -TARGET = desktop-editor +TARGET = lumina-fileinfo TEMPLATE = app isEmpty(PREFIX) { PREFIX = /usr/local } +target.path = $$PREFIX/bin isEmpty(LIBPREFIX) { LIBPREFIX = $$PREFIX/lib @@ -27,6 +28,13 @@ HEADERS += dialog.h FORMS += dialog.ui +RESOURCES+= lumina-fileinfo.qrc + INCLUDEPATH += $$PREFIX/include LIBS += -L$$LIBPREFIX -lLuminaUtils + +desktop.files=lumina-search.desktop +desktop.path=$$PREFIX/share/applications/ + +INSTALLS += target desktop diff --git a/desktop-editor/main.cpp b/lumina-fileinfo/main.cpp index 39a96321..deefd46f 100644 --- a/desktop-editor/main.cpp +++ b/lumina-fileinfo/main.cpp @@ -13,7 +13,7 @@ int main(int argc, char *argv[]) } else { w.MissingInputs(); } - a.setApplicationName("Desktop Editor"); + a.setApplicationName("Lumina File Info"); w.show(); return a.exec(); @@ -8,5 +8,6 @@ SUBDIRS+= libLumina \ lumina-screenshot \ lumina-search \ lumina-info \ - lumina-xconfig + lumina-xconfig \ + lumina-fileinfo |