summaryrefslogtreecommitdiff
path: root/noncore/tools/opie-sh/opie-sh.cpp
Unidiff
Diffstat (limited to 'noncore/tools/opie-sh/opie-sh.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/tools/opie-sh/opie-sh.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/noncore/tools/opie-sh/opie-sh.cpp b/noncore/tools/opie-sh/opie-sh.cpp
index e898cb1..96b4b93 100644
--- a/noncore/tools/opie-sh/opie-sh.cpp
+++ b/noncore/tools/opie-sh/opie-sh.cpp
@@ -90,24 +90,25 @@ int myMessageBox(int wi, int h, QWidget *w, int argc, QStringList args)
90 switch(mbox->exec() ) 90 switch(mbox->exec() )
91 { 91 {
92 case 0: 92 case 0:
93 return -1; 93 return -1;
94 case 1: 94 case 1:
95 return -1; 95 return -1;
96 case 2: 96 case 2:
97 return 0; 97 return 0;
98 case 3: 98 case 3:
99 return 1; 99 return 1;
100 case 4: 100 case 4:
101 return 2; 101 return 2;
102 default: return -1;
102 } 103 }
103} 104}
104 105
105void printusage() 106void printusage()
106{ 107{
107 printf("Usage instructions for Opie-sh\n"); 108 printf("Usage instructions for Opie-sh\n");
108 printf("Usage: opie-sh [dialog type] [type specific options]\n"); 109 printf("Usage: opie-sh [dialog type] [type specific options]\n");
109 printf("Types:\n"); 110 printf("Types:\n");
110 printf(" -m Message Box\n"); 111 printf(" -m Message Box\n");
111 printf(" -f [filename] View file [Default = stdin]\n"); 112 printf(" -f [filename] View file [Default = stdin]\n");
112 printf(" -i Input dialog\n"); 113 printf(" -i Input dialog\n");
113 printf(" -h --help These instructions\n"); 114 printf(" -h --help These instructions\n");
@@ -119,25 +120,25 @@ void printusage()
119 printf(" -e Use the error icon\n"); 120 printf(" -e Use the error icon\n");
120 printf(" -0 [text] First button text [Default = OK]\n"); 121 printf(" -0 [text] First button text [Default = OK]\n");
121 printf(" -1 [text] Second button text\n"); 122 printf(" -1 [text] Second button text\n");
122 printf(" -2 [text] Third button text\n"); 123 printf(" -2 [text] Third button text\n");
123 printf(" -g Disable fullscreen\n"); 124 printf(" -g Disable fullscreen\n");
124 printf("Input Dialog options:\n"); 125 printf("Input Dialog options:\n");
125 printf(" -s A single line of input (output to console)\n"); 126 printf(" -s A single line of input (output to console)\n");
126 printf(" -l List input (newline separated list read in from file)\n"); 127 printf(" -l List input (newline separated list read in from file)\n");
127 printf(" -b A list box, enabling multiple selections (input same as -l)\n"); 128 printf(" -b A list box, enabling multiple selections (input same as -l)\n");
128 printf(" -L [label] The label for the input field\n"); 129 printf(" -L [label] The label for the input field\n");
129 printf(" -F [filename] An input file (for when it makes sense) [Default = stdin]\n"); 130 printf(" -F [filename] An input file (for when it makes sense) [Default = stdin]\n");
130 printf(" -E Makes list input editable\n"); 131 printf(" -E Makes list input editable\n");
131 printf(" -g Disable fullscreen\n\0"); 132 printf(" -g Disable fullscreen\n");
132} 133}
133 134
134int fileviewer(QPEApplication *a, int argc, QStringList args) 135int fileviewer(QPEApplication *a, int argc, QStringList args)
135{ 136{
136 int i; 137 int i;
137 QString filename, title, icon; 138 QString filename, title, icon;
138 bool update=false; 139 bool update=false;
139 140
140 for(i=0; i < argc; i++) 141 for(i=0; i < argc; i++)
141 { 142 {
142 if(args[i] == "-f") 143 if(args[i] == "-f")
143 { 144 {