popup_message Class Reference

#include <popup_message.h>

Inheritance diagram for popup_message:

service_base

List of all members.

Public Types

enum  t_icon { icon_information, icon_error, icon_query }
typedef popup_message t_interface_entrypoint
typedef popup_message t_interface
typedef service_base t_interface_parent

Public Member Functions

virtual void show_ex (const char *p_msg, unsigned p_msg_length, const char *p_title, unsigned p_title_length, t_icon p_icon=icon_information)=0
void show (const char *p_msg, const char *p_title, t_icon p_icon=icon_information)

Static Public Member Functions

static void g_show_ex (const char *p_msg, unsigned p_msg_length, const char *p_title, unsigned p_title_length, t_icon p_icon=icon_information)
 Static helper function instantiating the service and activating the message dialog. See show_ex() for description of parameters.
static void g_show (const char *p_msg, const char *p_title, t_icon p_icon=icon_information)
 Static helper function instantiating the service and activating the message dialog. See show() for description of parameters.
static void g_complain (const char *what)
static void g_complain (const char *p_whatFailed, const std::exception &p_exception)
static void g_complain (const char *p_whatFailed, const char *msg)

Static Public Attributes

static const GUID class_guid


Detailed Description

This interface allows you to show generic nonmodal noninteractive dialog with a text message. This should be used instead of MessageBox where possible.
Usage: use popup_message::g_show / popup_message::g_show_ex static helpers, or static_api_ptr_t<popup_message>.
Note that all strings are UTF-8.

Member Typedef Documentation

Reimplemented from service_base.


Member Enumeration Documentation

Enumerator:
icon_information 
icon_error 
icon_query 


Member Function Documentation

virtual void popup_message::show_ex ( const char *  p_msg,
unsigned  p_msg_length,
const char *  p_title,
unsigned  p_title_length,
t_icon  p_icon = icon_information 
) [pure virtual]

Activates the popup dialog; returns immediately (the dialog remains visible).

Parameters:
p_msg Message to show (UTF-8 encoded string).
p_msg_length Length limit of message string to show, in bytes (actual string may be shorter if null terminator is encountered before). Set this to infinite to use plain null-terminated strings.
p_title Title of dialog to show (UTF-8 encoded string).
p_title_length Length limit of the title string, in bytes (actual string may be shorter if null terminator is encountered before). Set this to infinite to use plain null-terminated strings.
p_icon Icon of the dialog - can be set to icon_information, icon_error or icon_query.

void popup_message::show ( const char *  p_msg,
const char *  p_title,
t_icon  p_icon = icon_information 
) [inline]

Activates the popup dialog; returns immediately (the dialog remains visible); helper function built around show_ex(), takes null terminated strings with no length limit parameters.

Parameters:
p_msg Message to show (UTF-8 encoded string).
p_title Title of dialog to show (UTF-8 encoded string).
p_icon Icon of the dialog - can be set to icon_information, icon_error or icon_query.

static void popup_message::g_show_ex ( const char *  p_msg,
unsigned  p_msg_length,
const char *  p_title,
unsigned  p_title_length,
t_icon  p_icon = icon_information 
) [static]

Static helper function instantiating the service and activating the message dialog. See show_ex() for description of parameters.

static void popup_message::g_show ( const char *  p_msg,
const char *  p_title,
t_icon  p_icon = icon_information 
) [inline, static]

Static helper function instantiating the service and activating the message dialog. See show() for description of parameters.

static void popup_message::g_complain ( const char *  what  )  [inline, static]

static void popup_message::g_complain ( const char *  p_whatFailed,
const std::exception &  p_exception 
) [inline, static]

static void popup_message::g_complain ( const char *  p_whatFailed,
const char *  msg 
) [inline, static]


Member Data Documentation

const GUID popup_message::class_guid [static]

Initial value:

 
{ 0xd5cac75a, 0x3023, 0x4dce, { 0x8b, 0xd, 0xb5, 0x2, 0xbd, 0x5, 0x6a, 0x7c } }


The documentation for this class was generated from the following files:

Generated on Thu Aug 28 21:15:57 2008 for foobar2000 SDK by  doxygen 1.5.5