author | spiralman <spiralman> | 2002-05-27 00:59:37 (UTC) |
---|---|---|
committer | spiralman <spiralman> | 2002-05-27 00:59:37 (UTC) |
commit | d3451ccc7191bc2f761bae12b50c7ce274647bdb (patch) (side-by-side diff) | |
tree | f96f3c210de2c91d793d999e19bbcbc81ff02a99 /noncore/tools | |
parent | 95d2a3806a39bb31c9cca38c2c6158ecb77818e9 (diff) | |
download | opie-d3451ccc7191bc2f761bae12b50c7ce274647bdb.zip opie-d3451ccc7191bc2f761bae12b50c7ce274647bdb.tar.gz opie-d3451ccc7191bc2f761bae12b50c7ce274647bdb.tar.bz2 |
added help files and an icon in the Applications tab
-rw-r--r-- | noncore/tools/opie-sh/fviewer.cpp | 4 | ||||
-rw-r--r-- | noncore/tools/opie-sh/fviewer.h | 3 | ||||
-rw-r--r-- | noncore/tools/opie-sh/opie-sh.control | 5 | ||||
-rw-r--r-- | noncore/tools/opie-sh/opie-sh.cpp | 14 |
4 files changed, 19 insertions, 7 deletions
diff --git a/noncore/tools/opie-sh/fviewer.cpp b/noncore/tools/opie-sh/fviewer.cpp index 5dc09ff..882c72c 100644 --- a/noncore/tools/opie-sh/fviewer.cpp +++ b/noncore/tools/opie-sh/fviewer.cpp @@ -16,8 +16,10 @@ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA #include "fviewer.h" -FViewer::FViewer(QString filename, QString title, QWidget *parent=0, const char*name=0):QWidget(parent, name) +FViewer::FViewer(QString icon, QString filename, QString title, QWidget *parent=0, const char*name=0):QWidget(parent, name) { QVBoxLayout *layout = new QVBoxLayout(this); + setIcon(Resource::loadPixmap("opie-sh")); + textView = new QTextBrowser(this, "textview"); layout->addWidget(textView); diff --git a/noncore/tools/opie-sh/fviewer.h b/noncore/tools/opie-sh/fviewer.h index 488b6ed..cd5206c 100644 --- a/noncore/tools/opie-sh/fviewer.h +++ b/noncore/tools/opie-sh/fviewer.h @@ -22,4 +22,5 @@ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA #include <qtimer.h> #include <qdir.h> +#include <qpe/resource.h> class FViewer :public QWidget @@ -27,5 +28,5 @@ class FViewer :public QWidget Q_OBJECT public: - FViewer(QString filename, QString title, QWidget *parent=0, const char*name=0); + FViewer(QString icon, QString filename, QString title, QWidget *parent=0, const char*name=0); private: QFile *file; diff --git a/noncore/tools/opie-sh/opie-sh.control b/noncore/tools/opie-sh/opie-sh.control index e9b13a5..8f586fe 100644 --- a/noncore/tools/opie-sh/opie-sh.control +++ b/noncore/tools/opie-sh/opie-sh.control @@ -1,8 +1,9 @@ -Files: bin/opie-sh pics/opie-sh/*.png +Files: bin/opie-sh* apps/Applications/opie-sh.desktop pics/opie-sh/*.png help/opie-sh/*.html Priority: optional +Package: opie-sh Section: opie/applications Maintainer: Thomas Stephens <spiralman@softhome.net> Architecture: arm -Version: 0.4-$SUB_VERSION +Version: 0.5-$SUB_VERSION Depends: opie-base ($QPE_VERSION) License: GPL diff --git a/noncore/tools/opie-sh/opie-sh.cpp b/noncore/tools/opie-sh/opie-sh.cpp index a1b8035..e898cb1 100644 --- a/noncore/tools/opie-sh/opie-sh.cpp +++ b/noncore/tools/opie-sh/opie-sh.cpp @@ -129,5 +129,5 @@ void printusage() printf(" -F [filename] An input file (for when it makes sense) [Default = stdin]\n"); printf(" -E Makes list input editable\n"); - printf(" -g Disable fullscreen\n"); + printf(" -g Disable fullscreen\n\0"); } @@ -135,5 +135,5 @@ int fileviewer(QPEApplication *a, int argc, QStringList args) { int i; - QString filename, title; + QString filename, title, icon; bool update=false; @@ -148,4 +148,9 @@ int fileviewer(QPEApplication *a, int argc, QStringList args) } + if(args[i] == "-I") + { + icon=args[i+1]; + } + if(args[i] == "-t") { @@ -153,5 +158,5 @@ int fileviewer(QPEApplication *a, int argc, QStringList args) } } - FViewer *fview = new FViewer(filename, title, 0, (QString) "fileviewer"); + FViewer *fview = new FViewer(icon, filename, title, 0, (QString) "fileviewer"); a->setMainWidget(fview); fview->showMaximized(); @@ -194,6 +199,9 @@ int input(int wi, int h, QWidget *w, int argc, QStringList args) if(args[i] == "-F") { + if(args[i+1][0] != '-') + { filename = args[i+1]; } + } if(args[i] =="-E") |