Inheritance diagram for os::IconDirectoryView:
Public Member Functions | |
IconDirectoryView (const Rect &cFrame, const String &cPath, uint32 nResizeMask=CF_FOLLOW_LEFT|CF_FOLLOW_TOP) | |
Creates a new directory view. | |
~IconDirectoryView () | |
void | ReRead () |
Rereads the directory content. | |
void | SetPath (const String &cPath) |
Sets the current path. | |
String | GetPath () const |
Returns the current path. | |
Image * | GetDirIcon () const |
Returns the icon of the current directory. | |
bool | JobsPending () const |
Returns whether there are still pending jobs. | |
void | SetDirChangeMsg (Message *pcMsg) |
Sets the message that is sent when the directory changes. | |
void | SetDirectoryLocked (bool bLocked) |
Sets whether the current directory is locked. | |
void | SetAutoLaunch (bool bAutoLaunch) |
Sets whether invoked files are automatically launched. | |
virtual void | DirChanged (const String &cNewPath) |
virtual void | Invoked (uint nIcon, os::IconData *pcData) |
Called when an icon is invoked. | |
virtual void | DragSelection (os::Point cStartPoint) |
Called when an icon should be dragged. | |
virtual void | OpenContextMenu (os::Point cPosition, bool bMouseOverIcon) |
Called when the context menu of one icon should be opened. | |
virtual void | HandleMessage (Message *pcMessage) |
Handle a message targeted at this handler. | |
virtual void | AttachedToWindow () |
virtual void | DetachedFromWindow () |
virtual void | MouseUp (const Point &cPosition, uint32 nButtons, Message *pcData) |
Hook called by the system when a mouse button is release. | |
virtual void | MouseMove (const Point &cNewPos, int nCode, uint32 nButtons, Message *pcData) |
Hook called by the system when the mouse is moved. | |
virtual void | KeyDown (const char *pzString, const char *pzRawString, uint32 nQualifiers) |
Hook called by the system when a key is pressed while the view has focus. | |
Friends | |
class | os_priv::DirKeeper |
Classes | |
class | Private |
IconDirectoryView::IconDirectoryView | ( | const Rect & | cFrame, | |
const String & | cPath, | |||
uint32 | nResizeMask = CF_FOLLOW_LEFT | CF_FOLLOW_TOP | |||
) |
cFrame | - Frame. | |
cPath | - The start path. Can be set afterwards with SetPath(). | |
nResizeMask | - ResizeMask. |
IconDirectoryView::~IconDirectoryView | ( | ) |
void IconDirectoryView::ReRead | ( | ) |
void IconDirectoryView::SetPath | ( | const String & | cPath | ) |
cPath | - The new path. Please make sure that is is valid. |
os::String IconDirectoryView::GetPath | ( | ) | const |
os::Image * IconDirectoryView::GetDirIcon | ( | ) | const |
bool IconDirectoryView::JobsPending | ( | ) | const |
void IconDirectoryView::SetDirChangeMsg | ( | Message * | pcMsg | ) |
pcMsg | - The message. |
void IconDirectoryView::SetDirectoryLocked | ( | bool | bLocked | ) |
bLocked | - Enables/Disables this feature. |
void IconDirectoryView::SetAutoLaunch | ( | bool | bAutoLaunch | ) |
bAutoLaunch | - Enables/Disables this feature. |
void IconDirectoryView::DirChanged | ( | const String & | cNewPath | ) | [virtual] |
void IconDirectoryView::Invoked | ( | uint | nIcon, | |
os::IconData * | pcData | |||
) | [virtual] |
nIcon | - Index of the invoked icon. | |
pcData | - Data of the invoked icon. |
Reimplemented from os::IconView.
void IconDirectoryView::DragSelection | ( | os::Point | cStartPoint | ) | [virtual] |
cStartPoint | - Start position of the drag. |
Reimplemented from os::IconView.
void IconDirectoryView::OpenContextMenu | ( | os::Point | cPosition, | |
bool | bMouseOverIcon | |||
) | [virtual] |
cPosition | - Position. | |
bMouseOverIcon | - Whether the contextmenu of an icon should be opened. |
Reimplemented from os::IconView.
void IconDirectoryView::HandleMessage | ( | Message * | pcMessage | ) | [virtual] |
pcMessage
is also available through os::Looper::GetCurrentMessage() and os::Looper::DetachCurrentMessage() until this member returns. This is normally not very usefull for HandleMessage() itself but it can be convinient for other members called from HandleMessage() in case they need data from the message that was not passed on from HandleMessage(). pcMessage | The message that should be handled. This message will be deleted by the looper when HandleMessage() returns unless you detach it with os::Looper::DetachCurrentMessage(), |
Reimplemented from os::Handler.
void IconDirectoryView::AttachedToWindow | ( | ) | [virtual] |
Reimplemented from os::Control.
void IconDirectoryView::DetachedFromWindow | ( | ) | [virtual] |
Reimplemented from os::Control.
void IconDirectoryView::MouseUp | ( | const Point & | cPosition, | |
uint32 | nButtons, | |||
Message * | pcData | |||
) | [virtual] |
pcData
member will point to a Message containing the dragged data. Look at BeginDrag() for a more detailed description of the drag and drop system. cPosition | Mouse position in the views coordinate system at the time the mouse was pressed. | |
nButtons | Index of the pressed button. Buttons start at 1 for the left button, 2 for the right button, 3 for the middle button. Additional buttons might be supported by the mouse driver and will then be assigned numbers from 4 and up. | |
pcData | Pointer to a Message object containing the dragged data if this mouse-up was the end of a drag and drop operation. If no data was dragged it will be NULL. |
Reimplemented from os::View.
void IconDirectoryView::MouseMove | ( | const Point & | cNewPos, | |
int | nCode, | |||
uint32 | nButtons, | |||
Message * | pcData | |||
) | [virtual] |
cNewPos | New mouse position given in the views coordinate system. | |
nCode | Enter/exit code. This is MOUSE_ENTERED when the mouse first enter the view, MOUSE_EXITED when the mouse leaves the view, MOUSE_INSIDE whenever the mouse move withing the boundary of the view and MOUSE_OUTSIDE when the mouse move outside the view (will only happen if the view has focus). | |
nButtons | Bitmask telling which buttons that are currently pressed. Bit 0 is button 1 (left), bit 1 is button 2 (right), and bit 2 is button 3 (middle), and so on. | |
pcData | Pointer to a Message object containing the dragged data if the user is in the middle of a drag and drop operation. Otherwise this pointer is NULL. Look at BeginDrag() for a more detailed description of the drag and drop system. |
Reimplemented from os::View.
void IconDirectoryView::KeyDown | ( | const char * | pzString, | |
const char * | pzRawString, | |||
uint32 | nQualifiers | |||
) | [virtual] |
pzString | String containing a single UTF-8 encoded character. This is the character generated by the pressed key according to the current keymap accounting for any qualifiers that might be pressed. | |
pzRawString | Same as pzString except that the key is converted without accounting for qualifiers. Ie. if 'A' is pressed while pressing <SHIFT> pzString will contain 'A' and pzRawString will contain 'a'. | |
nQualifiers | Bitmask describing which qualifiers that was active when the key was pressed. |
Reimplemented from os::View.
friend class os_priv::DirKeeper [friend] |