Panda3D

Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Protected Attributes | List of all members
TaskManagerWidget Class Reference
Inheritance diagram for TaskManagerWidget:

## Public Member Functions
| __init__ (self, parent, taskMgr)
| onDestroy (self)
| popupMenu (self, event)
| removeCurrentTask (self)
| removeMatchingTasks (self)
| removeTaskHook (self, task)
| setCurrentTask (self, event=None)
| spawnTaskHook (self, task)
| toggleTaskMgrVerbose (self)
| updateTaskListBox (self)
Public Member Functions inherited from DirectObject
| __init__ (self)
| accept (self, event, method, extraArgs=[])
| acceptOnce (self, event, method, extraArgs=[])
| addTask (self, *args, **kwargs)
| detectLeaks (self)
| doMethodLater (self, *args, **kwargs)
| getAllAccepting (self)
| ignore (self, event)
| ignoreAll (self)
| isAccepting (self, event)
| isIgnoring (self, event)
| removeAllTasks (self)
| removeTask (self, taskOrName)

## Public Attributes
dict | currentTask = None
| dynamicUpdate
| parent = parent
| popupMenu
| removeButton
| removeMatchingButton
| removeTaskHook
| setCurrentTask = self.taskListBox.component('listbox')
| spawnTaskHook = 1)
| taskListBox
| taskMgr = taskMgr
| taskMgrVerbose = IntVar()
| update

## Protected Attributes
| _popupMenu
Protected Attributes inherited from DirectObject
dict | _taskList = {}

## Additional Inherited Members
Static Public Attributes inherited from DirectObject
| accept_once = acceptOnce
| add_task = addTask
| detect_leaks = detectLeaks
| do_method_later = doMethodLater
| get_all_accepting = getAllAccepting
| ignore_all = ignoreAll
| is_accepting = isAccepting
| is_ignoring = isIgnoring
| remove_all_tasks = removeAllTasks
| remove_task = removeTask
Protected Member Functions inherited from DirectObject
| _addTask (self, task)
| _clearTask (self, task)

## Detailed Description

    TaskManagerWidget class: this class contains methods for creating
    a panel to control taskManager tasks.

## Constructor & Destructor Documentation

## ◆ __init__()

__init__ | ( |  | self,
|  |  | parent,
|  |  | taskMgr )

    TaskManagerWidget class pops up a control panel to view/delete
    tasks managed by the taskManager.

## Member Function Documentation

## ◆ onDestroy()

onDestroy | ( |  | self | ) |

## ◆ popupMenu()

popupMenu | ( |  | self,
|  |  | event )

    listbox = self.taskListBox.component('listbox')
    index = listbox.nearest(event.y)
    listbox.selection_clear(0)
    listbox.activate(index)
    self.taskListBox.select_set(index)
    self.setCurrentTask()

## ◆ removeCurrentTask()

removeCurrentTask | ( |  | self | ) |

## ◆ removeMatchingTasks()

removeMatchingTasks | ( |  | self | ) |

## ◆ removeTaskHook()

removeTaskHook | ( |  | self,
|  |  | task )

## ◆ setCurrentTask()

setCurrentTask | ( |  | self,
|  |  | event = None )

## ◆ spawnTaskHook()

spawnTaskHook | ( |  | self,
|  |  | task )

## ◆ toggleTaskMgrVerbose()

toggleTaskMgrVerbose | ( |  | self | ) |

## ◆ updateTaskListBox()

updateTaskListBox | ( |  | self | ) |

## Member Data Documentation

## ◆ _popupMenu

_popupMenu
| protected

Initial value:
= Menu(self.taskListBox.component('listbox'),
tearoff = 0)

## ◆ currentTask

currentTask = None

## ◆ dynamicUpdate

dynamicUpdate

Initial value:
= Checkbutton(
controlsFrame,
text = 'Dynamic Update',
variable = self.taskMgrVerbose,
command = self.toggleTaskMgrVerbose)

## ◆ parent

parent = parent

## ◆ popupMenu

popupMenu

## ◆ removeButton

removeButton

Initial value:
= Button(controlsFrame, text = 'Remove Task',
command = self.removeCurrentTask)

## ◆ removeMatchingButton

removeMatchingButton

Initial value:
= Button(controlsFrame,
text = 'Remove Matching Tasks',
command = self.removeMatchingTasks)

## ◆ removeTaskHook

removeTaskHook

## ◆ setCurrentTask

setCurrentTask = self.taskListBox.component('listbox')

## ◆ spawnTaskHook

spawnTaskHook = 1)

## ◆ taskListBox

taskListBox

Initial value:
= Pmw.ScrolledListBox(
parent,
labelpos = NW, label_text = 'Tasks:',
label_font=('MSSansSerif', 10, 'bold'),
listbox_takefocus = 1,
items = [],
selectioncommand = self.setCurrentTask)

## ◆ taskMgr

taskMgr = taskMgr

## ◆ taskMgrVerbose

taskMgrVerbose = IntVar()

## ◆ update

update

Initial value:
= Button(
controlsFrame,
text = 'Update',
command = self.updateTaskListBox)