[Aptitude-svn-commit] r3545 - in branches/aptitude-0.3/aptitude: . src
Daniel Burrows
dburrows@costa.debian.org
Sat, 02 Jul 2005 14:59:17 +0000
Author: dburrows
Date: Sat Jul 2 14:59:14 2005
New Revision: 3545
Modified:
branches/aptitude-0.3/aptitude/ChangeLog
branches/aptitude-0.3/aptitude/src/ui.h
Log:
Cancel that.
Modified: branches/aptitude-0.3/aptitude/ChangeLog
==============================================================================
--- branches/aptitude-0.3/aptitude/ChangeLog (original)
+++ branches/aptitude-0.3/aptitude/ChangeLog Sat Jul 2 14:59:14 2005
@@ -2,6 +2,12 @@
* src/ui.h:
+ Undo that last change: most of the code passes statically
+ translated strings into those routines, so it will be a lot
+ simpler to do the transcoding in ui.cc.
+
+ * src/ui.h:
+
Use wstrings in the UI's external interface.
* src/pkg_info_screen.cc:
Modified: branches/aptitude-0.3/aptitude/src/ui.h
==============================================================================
--- branches/aptitude-0.3/aptitude/src/ui.h (original)
+++ branches/aptitude-0.3/aptitude/src/ui.h Sat Jul 2 14:59:14 2005
@@ -137,12 +137,12 @@
* \param menudesc the description of the generated menu item
* \param tablabel the label of the corresponding tab
*/
-void add_main_widget(vscreen_widget *w, const std::wstring &menuref,
- const std::wstring &menudesc,
- const std::wstring &tablabel);
-void insert_main_widget(vscreen_widget *w, const std::wstring &menuref,
- const std::wstring &menudesc,
- const std::wstring &tablabel);
+void add_main_widget(vscreen_widget *w, const std::string &menuref,
+ const std::string &menudesc,
+ const std::string &tablabel);
+void insert_main_widget(vscreen_widget *w, const std::string &menuref,
+ const std::string &menudesc,
+ const std::string &tablabel);
/** Returns the currently active main widget. */
vscreen_widget *active_main_widget();
@@ -160,30 +160,30 @@
* always be "noninvasive" (typically a bar at the bottom of
* the screen).
* \param title if a new view is generated, this string is
- * used as its title.
+ * used as its title; it will be transcoded.
* \param longtitle if a new view is generated, this string is
- * used as its long title.
+ * used as its long title; it will be transcoded.
* \param abortslot the slot to trigger if the download is aborted.
*
* \return the new download manager.
*/
download_manager *gen_download_progress(bool force_noninvasive,
- const std::wstring &title,
- const std::wstring &longtitle,
- const std::wstring &tablabel,
+ const std::string &title,
+ const std::string &longtitle,
+ const std::string &tablabel,
slot0arg abortslot);
// Asks the user for simple input (the question will appear in a "minibuffer"
// or in a dialog according to preferences)
-void prompt_string(const std::wstring &prompt,
- const std::wstring &text,
+void prompt_string(const std::string &prompt,
+ const std::string &text,
slotarg<sigc::slot1<void, string> > slot,
slotarg<sigc::slot0<void> > cancel_slot,
slotarg<sigc::slot1<void, string> > changed_slot,
vs_editline::history_list *history);
-void prompt_yesno(const std::wstring &prompt,
+void prompt_yesno(const std::string &prompt,
bool deflt,
slot0arg yesslot,
slot0arg noslot);
@@ -201,10 +201,19 @@
slot0arg okslot,
const style &st=style());
-void show_message(const std::wstring &msg,
+/** Display the given message, either in a popup dialog box or as a
+ * "transient" message at the bottom of the screen. The message
+ * should be expected to be relatively short (ie, short enough to not
+ * need a scrollbar on a 'reasonable' terminal); it will be
+ * paragraph-wrapped as necessary.
+ *
+ * \param msg the message to display; will be transcoded
+ * \param okslot an optional slot to be called when the message is dismissed
+ */
+void show_message(const std::string &msg,
slot0arg okslot=NULL,
- const style &st=style());
-
+ const style &st=style())
+;
// Can be used to manually pop up an error dialog, if necessary.
void check_apt_errors();