Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes

gui2::tpassword_box Class Reference

#include <password_box.hpp>

Inheritance diagram for gui2::tpassword_box:
Inheritance graph
[legend]
Collaboration diagram for gui2::tpassword_box:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 tpassword_box ()
virtual void set_value (const std::string &text)
 Inherited from ttext_.
std::string get_real_value () const

Protected Member Functions

void insert_char (const Uint16 unicode)
 Inserts a character at the cursor.
void delete_char (const bool before_cursor)
 Inherited from ttext_.
void paste_selection (const bool mouse)
 Pastes the current selection.

Private Member Functions

void handle_key_backspace (SDLMod modifier, bool &handled)
 Backspace key pressed.
void handle_key_delete (SDLMod modifier, bool &handled)
 Delete key pressed.
void pre_function ()
void post_function ()
const std::string & get_control_type () const
 Inherited from ttext_box.

Private Attributes

std::string real_value_

Detailed Description

Definition at line 32 of file password_box.hpp.


Constructor & Destructor Documentation

gui2::tpassword_box::tpassword_box (  )  [inline]

Definition at line 53 of file password_box.hpp.


Member Function Documentation

void gui2::tpassword_box::delete_char ( const bool  before_cursor  )  [protected, virtual]

Inherited from ttext_.

Reimplemented from gui2::ttext_box.

Definition at line 57 of file password_box.cpp.

References post_function(), and pre_function().

Referenced by handle_key_backspace(), and handle_key_delete().

Here is the call graph for this function:

Here is the caller graph for this function:

const std::string & gui2::tpassword_box::get_control_type (  )  const [private, virtual]

Inherited from ttext_box.

Reimplemented from gui2::ttext_box.

Definition at line 134 of file password_box.cpp.

References type.

std::string gui2::tpassword_box::get_real_value (  )  const [inline]

Definition at line 57 of file password_box.hpp.

References real_value_.

void gui2::tpassword_box::handle_key_backspace ( SDLMod  modifier,
bool &  handled 
) [private, virtual]

Backspace key pressed.

Unmodified Deletes the character before the cursor, ignored if at the beginning of the data. Control Ignored. Shift Ignored. Alt Ignored.

Reimplemented from gui2::ttext_.

Definition at line 63 of file password_box.cpp.

References DBG_GUI_E, delete_char(), gui2::ttext_box::delete_selection(), gui2::ttext_::get_selection_length(), gui2::ttext_::get_selection_start(), LOG_SCOPE_HEADER, post_function(), and pre_function().

Here is the call graph for this function:

void gui2::tpassword_box::handle_key_delete ( SDLMod  modifier,
bool &  handled 
) [private, virtual]

Delete key pressed.

Unmodified If there is a selection that's deleted. Else if not at the end of the data the character after the cursor is deleted. Else the key is ignored. ignored if at the beginning of the data. Control Ignored. Shift Ignored. Alt Ignored.

Reimplemented from gui2::ttext_.

Definition at line 79 of file password_box.cpp.

References DBG_GUI_E, delete_char(), gui2::ttext_box::delete_selection(), gui2::ttext_::get_selection_length(), gui2::ttext_::get_selection_start(), LOG_SCOPE_HEADER, post_function(), pre_function(), and gui2::ttext_::text().

Here is the call graph for this function:

void gui2::tpassword_box::insert_char ( const Uint16  unicode  )  [protected, virtual]

Inserts a character at the cursor.

This function is preferred over set_text since it's optimized for updating the internal bookkeeping.

Parameters:
unicode The unicode value of the character to insert.

Reimplemented from gui2::ttext_.

Definition at line 51 of file password_box.cpp.

References post_function(), and pre_function().

Here is the call graph for this function:

void gui2::tpassword_box::paste_selection ( const bool  mouse  )  [protected, virtual]

Pastes the current selection.

Reimplemented from gui2::ttext_.

Definition at line 95 of file password_box.cpp.

References post_function(), and pre_function().

Here is the call graph for this function:

void gui2::tpassword_box::post_function (  )  [private]
void gui2::tpassword_box::pre_function (  )  [private]
void gui2::tpassword_box::set_value ( const std::string &  text  )  [virtual]

Inherited from ttext_.

Reimplemented from gui2::ttext_.

Definition at line 45 of file password_box.cpp.

References gui2::ttext_::get_value(), and real_value_.

Referenced by post_function(), and pre_function().

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

std::string gui2::tpassword_box::real_value_ [private]

Definition at line 77 of file password_box.hpp.

Referenced by get_real_value(), post_function(), pre_function(), and set_value().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated by doxygen 1.7.1 on Thu May 24 2012 01:23:10 for The Battle for Wesnoth
Gna! | Forum | Wiki | CIA | devdocs