llviewchildren.h

Go to the documentation of this file.
00001 
00032 #ifndef LL_LLVIEWCHILDREN_H
00033 #define LL_LLVIEWCHILDREN_H
00034 
00035 class LLPanel;
00036 
00037 class LLViewChildren
00038         // makes it easy to manipulate children of a view by id safely
00039         // encapsulates common operations into simple, one line calls
00040 {
00041 public:
00042         LLViewChildren(LLPanel& parent);
00043         
00044         // all views
00045         void show(const char* id, bool visible = true);
00046         void hide(const char* id) { show(id, false); }
00047 
00048         void enable(const char* id, bool enabled = true);
00049         void disable(const char* id) { enable(id, false); };
00050 
00051         //
00052         // LLTextBox
00053         void setText(const char* id,
00054                 const std::string& text, bool visible = true);
00055         void setWrappedText(const char* id,
00056                 const std::string& text, bool visible = true);
00057 
00058         // LLIconCtrl
00059         enum Badge { BADGE_OK, BADGE_NOTE, BADGE_WARN, BADGE_ERROR };
00060         
00061         void setBadge(const char* id, Badge b, bool visible = true);
00062 
00063         
00064         // LLButton
00065         void setAction(const char* id, void(*function)(void*), void* value);
00066 
00067 
00068 private:
00069         LLPanel& mParent;
00070 };
00071 
00072 #endif

Generated on Thu Jul 1 06:09:26 2010 for Second Life Viewer by  doxygen 1.4.7