Changeset View
Changeset View
Standalone View
Standalone View
kioclient/kioclient.cpp
Show First 20 Lines • Show All 57 Lines • ▼ Show 20 Line(s) | 54 | { | |||
---|---|---|---|---|---|
58 | } | 58 | } | ||
59 | return ret; | 59 | return ret; | ||
60 | } | 60 | } | ||
61 | 61 | | |||
62 | #ifdef KIOCLIENT_AS_KIOCLIENT5 | 62 | #ifdef KIOCLIENT_AS_KIOCLIENT5 | ||
63 | static void usage() | 63 | static void usage() | ||
64 | { | 64 | { | ||
65 | puts(i18n("\nSyntax:\n").toLocal8Bit().constData()); | 65 | puts(i18n("\nSyntax:\n").toLocal8Bit().constData()); | ||
66 | puts(i18n(" kioclient openProperties 'url'\n" | 66 | puts(i18n(" kioclient5 openProperties 'url'\n" | ||
67 | " # Opens a properties menu\n\n").toLocal8Bit().constData()); | 67 | " # Opens a properties menu\n\n").toLocal8Bit().constData()); | ||
68 | puts(i18n(" kioclient exec 'url' ['mimetype']\n" | 68 | puts(i18n(" kioclient5 exec 'url' ['mimetype']\n" | ||
69 | " # Tries to open the document pointed to by 'url', in the application\n" | 69 | " # Tries to open the document pointed to by 'url', in the application\n" | ||
70 | " # associated with it in KDE. You may omit 'mimetype'.\n" | 70 | " # associated with it in KDE. You may omit 'mimetype'.\n" | ||
71 | " # In this case the mimetype is determined\n" | 71 | " # In this case the mimetype is determined\n" | ||
72 | " # automatically. Of course URL may be the URL of a\n" | 72 | " # automatically. Of course URL may be the URL of a\n" | ||
73 | " # document, or it may be a *.desktop file.\n" | 73 | " # document, or it may be a *.desktop file.\n" | ||
74 | " # 'url' can be an executable, too.\n").toLocal8Bit().constData()); | 74 | " # 'url' can be an executable, too.\n").toLocal8Bit().constData()); | ||
75 | puts(i18n(" kioclient move 'src' 'dest'\n" | 75 | puts(i18n(" kioclient5 move 'src' 'dest'\n" | ||
76 | " # Moves the URL 'src' to 'dest'.\n" | 76 | " # Moves the URL 'src' to 'dest'.\n" | ||
77 | " # 'src' may be a list of URLs.\n").toLocal8Bit().constData()); | 77 | " # 'src' may be a list of URLs.\n").toLocal8Bit().constData()); | ||
78 | puts(i18n(" # 'dest' may be \"trash:/\" to move the files\n" | 78 | puts(i18n(" # 'dest' may be \"trash:/\" to move the files\n" | ||
79 | " # to the trash.\n").toLocal8Bit().constData()); | 79 | " # to the trash.\n").toLocal8Bit().constData()); | ||
80 | puts(i18n(" # the short version kioclient mv\n" | 80 | puts(i18n(" # the short version kioclient5 mv\n" | ||
81 | " # is also available.\n\n").toLocal8Bit().constData()); | 81 | " # is also available.\n\n").toLocal8Bit().constData()); | ||
82 | puts(i18n(" kioclient download ['src']\n" | 82 | puts(i18n(" kioclient5 download ['src']\n" | ||
83 | " # Copies the URL 'src' to a user-specified location'.\n" | 83 | " # Copies the URL 'src' to a user-specified location'.\n" | ||
84 | " # 'src' may be a list of URLs, if not present then\n" | 84 | " # 'src' may be a list of URLs, if not present then\n" | ||
85 | " # a URL will be requested.\n\n").toLocal8Bit().constData()); | 85 | " # a URL will be requested.\n\n").toLocal8Bit().constData()); | ||
86 | puts(i18n(" kioclient copy 'src' 'dest'\n" | 86 | puts(i18n(" kioclient5 copy 'src' 'dest'\n" | ||
87 | " # Copies the URL 'src' to 'dest'.\n" | 87 | " # Copies the URL 'src' to 'dest'.\n" | ||
88 | " # 'src' may be a list of URLs.\n").toLocal8Bit().constData()); | 88 | " # 'src' may be a list of URLs.\n").toLocal8Bit().constData()); | ||
89 | puts(i18n(" # the short version kioclient cp\n" | 89 | puts(i18n(" # the short version kioclient5 cp\n" | ||
90 | " # is also available.\n\n").toLocal8Bit().constData()); | 90 | " # is also available.\n\n").toLocal8Bit().constData()); | ||
91 | puts(i18n(" kioclient cat 'url'\n" | 91 | puts(i18n(" kioclient5 cat 'url'\n" | ||
92 | " # Writes out the contents of 'url' to stdout\n\n").toLocal8Bit().constData()); | 92 | " # Writes out the contents of 'url' to stdout\n\n").toLocal8Bit().constData()); | ||
93 | puts(i18n(" kioclient ls 'url'\n" | 93 | puts(i18n(" kioclient5 ls 'url'\n" | ||
94 | " # Lists the contents of the directory 'url' to stdout\n\n").toLocal8Bit().constData()); | 94 | " # Lists the contents of the directory 'url' to stdout\n\n").toLocal8Bit().constData()); | ||
95 | puts(i18n(" kioclient remove 'url'\n" | 95 | puts(i18n(" kioclient5 remove 'url'\n" | ||
96 | " # Removes the URL\n" | 96 | " # Removes the URL\n" | ||
97 | " # 'url' may be a list of URLs.\n").toLocal8Bit().constData()); | 97 | " # 'url' may be a list of URLs.\n").toLocal8Bit().constData()); | ||
98 | puts(i18n(" # the short version kioclient rm\n" | 98 | puts(i18n(" # the short version kioclient5 rm\n" | ||
99 | " # is also available.\n\n").toLocal8Bit().constData()); | 99 | " # is also available.\n\n").toLocal8Bit().constData()); | ||
100 | 100 | | |||
101 | puts(i18n("*** Examples:\n").toLocal8Bit().constData()); | 101 | puts(i18n("*** Examples:\n").toLocal8Bit().constData()); | ||
102 | puts(i18n(" kioclient exec file:/home/weis/data/test.html\n" | 102 | puts(i18n(" kioclient5 exec file:/home/weis/data/test.html\n" | ||
103 | " // Opens the file with default binding\n\n").toLocal8Bit().constData()); | 103 | " // Opens the file with default binding\n\n").toLocal8Bit().constData()); | ||
104 | puts(i18n(" kioclient exec ftp://localhost/\n" | 104 | puts(i18n(" kioclient5 exec ftp://localhost/\n" | ||
105 | " // Opens new window with URL\n\n").toLocal8Bit().constData()); | 105 | " // Opens new window with URL\n\n").toLocal8Bit().constData()); | ||
106 | puts(i18n(" kioclient exec file:/root/Desktop/emacs.desktop\n" | 106 | puts(i18n(" kioclient5 exec file:/root/Desktop/emacs.desktop\n" | ||
107 | " // Starts emacs\n\n").toLocal8Bit().constData()); | 107 | " // Starts emacs\n\n").toLocal8Bit().constData()); | ||
108 | puts(i18n(" kioclient exec .\n" | 108 | puts(i18n(" kioclient5 exec .\n" | ||
109 | " // Opens the current directory. Very convenient.\n\n").toLocal8Bit().constData()); | 109 | " // Opens the current directory. Very convenient.\n\n").toLocal8Bit().constData()); | ||
110 | } | 110 | } | ||
111 | #endif | 111 | #endif | ||
112 | 112 | | |||
113 | int main( int argc, char **argv ) | 113 | int main( int argc, char **argv ) | ||
114 | { | 114 | { | ||
115 | #ifdef KIOCORE_ONLY | 115 | #ifdef KIOCORE_ONLY | ||
116 | QCoreApplication app(argc, argv); | 116 | QCoreApplication app(argc, argv); | ||
▲ Show 20 Lines • Show All 339 Lines • Show Last 20 Lines |