FS2_Open
Open source remastering of the Freespace 2 engine
UI_BUTTON Class Reference

#include <ui.h>

Inheritance diagram for UI_BUTTON:
UI_GADGET

Public Member Functions

virtual void draw ()
 
void set_hotkey_if_focus (int key)
 
int pressed ()
 
int double_clicked ()
 
int just_pressed ()
 
int just_highlighted ()
 
int button_down ()
 
int button_hilighted ()
 
void set_button_hilighted ()
 
void press_button ()
 
void create (UI_WINDOW *wnd, char *_text, int _x, int _y, int _w, int _h, int do_repeat=0, int ignore_focus=0)
 
void set_highlight_action (void(*_user_function)(void))
 
void set_disabled_action (void(*_user_function)(void))
 
void draw_forced (int frame_num)
 
void reset_status ()
 
void reset_timestamps ()
 
void skip_first_highlight_callback ()
 
void repeatable (int yes)
 
void set_custom_cursor_bmap (int bmap_id)
 
- Public Member Functions inherited from UI_GADGET
 UI_GADGET ()
 
virtual ~UI_GADGET ()
 
void base_create (UI_WINDOW *wnd, int _kind, int _x, int _y, int _w, int _h)
 
void set_focus ()
 
void clear_focus ()
 
int has_focus ()
 
void set_hotkey (int keycode)
 
void set_callback (void(*_user_function)(void))
 
void disable ()
 
void enable (int n=1)
 
void capture_mouse ()
 
int mouse_captured (UI_GADGET *gadget=NULL)
 
int disabled ()
 
int enabled ()
 
virtual void hide (int n)
 
virtual void hide ()
 
virtual void unhide ()
 
void update_dimensions (int _x, int _y, int _w, int _h)
 
void get_dimensions (int *_x, int *_y, int *_w, int *_h)
 
int is_mouse_on ()
 
void get_mouse_pos (int *xx, int *yy)
 
void link_hotspot (int num)
 
int get_hotspot ()
 
int bmaps_used ()
 
int set_bmaps (char *ani_filename, int nframes=3, int start_frame=1)
 
void reset ()
 
virtual int is_hidden ()
 

Friends

class UI_SCROLLBAR
 
class UI_SLIDER2
 
class UI_DOT_SLIDER
 
class UI_DOT_SLIDER_NEW
 

Additional Inherited Members

- Public Attributes inherited from UI_GADGET
int bmap_ids [MAX_BMAPS_PER_GADGET]
 
- Protected Member Functions inherited from UI_GADGET
void drag_with_children (int dx, int dy)
 
void start_drag_with_children ()
 
void stop_drag_with_children ()
 
int is_mouse_on_children ()
 
void remove_from_family ()
 
void set_parent (UI_GADGET *_parent)
 
UI_GADGETget_next ()
 
UI_GADGETget_prev ()
 
int check_move ()
 
- Protected Attributes inherited from UI_GADGET
char * bm_filename
 
int kind
 
int hotkey
 
int x
 
int y
 
int w
 
int h
 
int m_flags
 
void(* user_function )(void)
 
int disabled_flag
 
int base_dragging
 
int base_drag_x
 
int base_drag_y
 
int base_start_x
 
int base_start_y
 
int hidden
 
int linked_to_hotspot
 
int hotspot_num
 
int uses_bmaps
 
int m_num_frames
 
UI_GADGETparent
 
UI_GADGETchildren
 
UI_GADGETprev
 
UI_GADGETnext
 
UI_WINDOWmy_wnd
 

Detailed Description

Definition at line 195 of file ui.h.

Member Function Documentation

int UI_BUTTON::button_down ( )

Definition at line 363 of file button.cpp.

int UI_BUTTON::button_hilighted ( )

Definition at line 387 of file button.cpp.

void UI_BUTTON::create ( UI_WINDOW wnd,
char *  _text,
int  _x,
int  _y,
int  _w,
int  _h,
int  do_repeat = 0,
int  ignore_focus = 0 
)

Definition at line 26 of file button.cpp.

int UI_BUTTON::double_clicked ( )

Definition at line 333 of file button.cpp.

void UI_BUTTON::draw ( )
virtual

Reimplemented from UI_GADGET.

Definition at line 120 of file button.cpp.

void UI_BUTTON::draw_forced ( int  frame_num)

Definition at line 104 of file button.cpp.

int UI_BUTTON::just_highlighted ( )

Definition at line 349 of file button.cpp.

int UI_BUTTON::just_pressed ( )

Definition at line 341 of file button.cpp.

void UI_BUTTON::press_button ( )

Definition at line 399 of file button.cpp.

int UI_BUTTON::pressed ( )

Definition at line 325 of file button.cpp.

void UI_BUTTON::repeatable ( int  yes)

Definition at line 420 of file button.cpp.

void UI_BUTTON::reset_status ( )

Definition at line 78 of file button.cpp.

void UI_BUTTON::reset_timestamps ( )

Definition at line 408 of file button.cpp.

void UI_BUTTON::set_button_hilighted ( )

Definition at line 393 of file button.cpp.

void UI_BUTTON::set_custom_cursor_bmap ( int  bmap_id)
inline

Definition at line 248 of file ui.h.

void UI_BUTTON::set_disabled_action ( void(*)(void _user_function)

Definition at line 380 of file button.cpp.

void UI_BUTTON::set_highlight_action ( void(*)(void _user_function)

Definition at line 375 of file button.cpp.

void UI_BUTTON::set_hotkey_if_focus ( int  key)

Definition at line 73 of file button.cpp.

void UI_BUTTON::skip_first_highlight_callback ( )

Definition at line 414 of file button.cpp.

Friends And Related Function Documentation

friend class UI_DOT_SLIDER
friend

Definition at line 199 of file ui.h.

friend class UI_DOT_SLIDER_NEW
friend

Definition at line 200 of file ui.h.

friend class UI_SCROLLBAR
friend

Definition at line 197 of file ui.h.

friend class UI_SLIDER2
friend

Definition at line 198 of file ui.h.


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