Wt examples
3.3.1
|
A single node in a file tree table. More...
#include <FileTreeTableNode.h>
Public Member Functions | |
FileTreeTableNode (const boost::filesystem::path &path) | |
Construct a new node for the given file. More... | |
![]() | |
WTreeTableNode (const WString &labelText, WIconPair *labelIcon=0, WTreeTableNode *parentNode=0) | |
void | setColumnWidget (int column, WWidget *item) |
WWidget * | columnWidget (int column) |
WTreeTable * | table () const |
virtual void | insertChildNode (int index, WTreeNode *node) |
![]() | |
WTreeNode (const WString &labelText, WIconPair *labelIcon=0, WTreeNode *parentNode=0) | |
~WTreeNode () | |
virtual WTree * | tree () const |
WText * | label () const |
WIconPair * | labelIcon () const |
void | setLabelIcon (WIconPair *labelIcon) |
void | addChildNode (WTreeNode *node) |
void | removeChildNode (WTreeNode *node) |
const std::vector< WTreeNode * > & | childNodes () const |
virtual int | displayedChildCount () const |
void | setChildCountPolicy (ChildCountPolicy policy) |
ChildCountPolicy | childCountPolicy () const |
void | setImagePack (const std::string &url) |
void | setLoadPolicy (LoadPolicy loadPolicy) |
bool | isExpanded () const |
void | setSelectable (bool selectable) |
virtual bool | isSelectable () const |
WTreeNode * | parentNode () const |
void | setNodeVisible (bool visible) |
void | setChildrenDecorated (bool decorated) |
void | setInteractive (bool interactive) |
void | expand () |
void | collapse () |
EventSignal< WMouseEvent > & | expanded () |
EventSignal< WMouseEvent > & | collapsed () |
Signal< bool > & | selected () |
![]() | |
WCompositeWidget (WContainerWidget *parent=0) | |
WCompositeWidget (WWidget *implementation, WContainerWidget *parent) | |
virtual const std::string | id () const |
virtual void | setPositionScheme (PositionScheme scheme) |
virtual PositionScheme | positionScheme () const |
virtual void | setOffsets (const WLength &offset, WFlags< Side > sides=All) |
virtual WLength | offset (Side s) const |
virtual void | resize (const WLength &width, const WLength &height) |
virtual WLength | width () const |
virtual WLength | height () const |
virtual void | setMinimumSize (const WLength &width, const WLength &height) |
virtual WLength | minimumWidth () const |
virtual WLength | minimumHeight () const |
virtual void | setMaximumSize (const WLength &width, const WLength &height) |
virtual WLength | maximumWidth () const |
virtual WLength | maximumHeight () const |
virtual void | setLineHeight (const WLength &height) |
virtual WLength | lineHeight () const |
virtual void | setFloatSide (Side s) |
virtual Side | floatSide () const |
virtual void | setClearSides (WFlags< Side > sides) |
virtual WFlags< Side > | clearSides () const |
virtual void | setMargin (const WLength &margin, WFlags< Side > sides=All) |
virtual WLength | margin (Side side) const |
virtual void | setHiddenKeepsGeometry (bool enabled) |
virtual bool | hiddenKeepsGeometry () const |
virtual void | setHidden (bool hidden, const WAnimation &animation=WAnimation()) |
virtual bool | isHidden () const |
virtual bool | isVisible () const |
virtual void | setDisabled (bool disabled) |
virtual bool | isDisabled () const |
virtual bool | isEnabled () const |
virtual void | setPopup (bool popup) |
virtual bool | isPopup () const |
virtual void | setInline (bool isInline) |
virtual bool | isInline () const |
virtual void | setDecorationStyle (const WCssDecorationStyle &style) |
virtual WCssDecorationStyle & | decorationStyle () |
virtual void | setStyleClass (const WString &styleClass) |
virtual WString | styleClass () const |
virtual void | addStyleClass (const WString &styleClass, bool force=false) |
virtual void | removeStyleClass (const WString &styleClass, bool force=false) |
virtual bool | hasStyleClass (const WString &styleClass) const |
virtual void | setVerticalAlignment (AlignmentFlag alignment, const WLength &length=WLength::Auto) |
virtual AlignmentFlag | verticalAlignment () const |
virtual WLength | verticalAlignmentLength () const |
virtual void | setToolTip (const WString &text, TextFormat textFormat=PlainText) |
virtual const WString & | toolTip () const |
virtual void | refresh () |
virtual void | setAttributeValue (const std::string &name, const WString &value) |
virtual WString | attributeValue (const std::string &name) const |
virtual void | setJavaScriptMember (const std::string &name, const std::string &value) |
virtual std::string | javaScriptMember (const std::string &name) const |
virtual void | callJavaScriptMember (const std::string &name, const std::string &args) |
virtual void | load () |
virtual bool | loaded () const |
virtual void | setTabIndex (int index) |
virtual int | tabIndex () const |
virtual void | setId (const std::string &id) |
virtual WWidget * | find (const std::string &name) |
virtual void | doJavaScript (const std::string &js) |
virtual void | propagateSetEnabled (bool enabled) |
![]() | |
virtual | ~WWidget () |
WWidget * | parent () const |
void | setWidth (const WLength &width) |
void | setHeight (const WLength &height) |
virtual void | positionAt (const WWidget *widget, Orientation orientation=Vertical) |
virtual void | toggleStyleClass (const WString &styleClass, bool add, bool force=false) |
std::string | jsRef () const |
virtual void | acceptDrops (const std::string &mimeType, const WString &hoverStyleClass=WString()) |
virtual void | stopAcceptDrops (const std::string &mimeType) |
virtual void | htmlText (std::ostream &out) |
bool | isRendered () const |
void | hide () |
void | animateHide (const WAnimation &animation) |
void | show () |
void | animateShow (const WAnimation &animation) |
void | enable () |
void | disable () |
bool | layoutSizeAware () const |
![]() | |
WObject (WObject *parent=0) | |
virtual | ~WObject () |
void | setObjectName (const std::string &name) |
virtual std::string | objectName () const |
void | resetLearnedSlots () |
void | resetLearnedSlot (void(T::*method)()) |
WStatelessSlot * | implementStateless (void(T::*method)()) |
WStatelessSlot * | implementStateless (void(T::*method)(), void(T::*undoMethod)()) |
WStatelessSlot * | implementJavaScript (void(T::*method)(), const std::string &jsCode) |
void | addChild (WObject *child) |
virtual void | removeChild (WObject *child) |
const std::vector< WObject * > & | children () const |
WObject * | parent () const |
Private Member Functions | |
virtual void | populate () |
Reimplements WTreeNode::populate to read files within a directory. More... | |
virtual bool | expandable () |
Reimplements WTreeNode::expandable. More... | |
Static Private Member Functions | |
static Wt::WIconPair * | createIcon (const boost::filesystem::path &path) |
Create the iconpair for representing the path. More... | |
Private Attributes | |
boost::filesystem::path | path_ |
The path. More... | |
Additional Inherited Members | |
![]() | |
enum | LoadPolicy |
enum | ChildCountPolicy |
![]() | |
static WString | tr (const char *key) |
![]() | |
LazyLoading | |
PreLoading | |
NextLevelLoading | |
Disabled | |
Enabled | |
Lazy | |
![]() | |
virtual void | setTable (WTreeTable *table) |
![]() | |
static WObject * | sender () |
A single node in a file tree table.
The node manages the details about one file, and if the file is a directory, populates a subtree with nodes for every directory item.
The tree node reimplements Wt::WTreeTableNode::populate() to populate a directory node only when the node is expanded. In this way, only directories that are actually browsed are loaded from disk.
Definition at line 28 of file FileTreeTableNode.h.
FileTreeTableNode::FileTreeTableNode | ( | const boost::filesystem::path & | path) |
|
staticprivate |
Create the iconpair for representing the path.
Definition at line 60 of file FileTreeTableNode.C.
|
privatevirtual |
Reimplements WTreeNode::expandable.
Reimplemented from Wt::WTreeNode.
Definition at line 90 of file FileTreeTableNode.C.
|
privatevirtual |
Reimplements WTreeNode::populate to read files within a directory.
Reimplemented from Wt::WTreeNode.
Definition at line 71 of file FileTreeTableNode.C.
|
private |
The path.
Definition at line 37 of file FileTreeTableNode.h.