kjots
Bookshelf Class Reference
#include <bookshelf.h>

Detailed Description
Definition at line 38 of file bookshelf.h.
Constructor & Destructor Documentation
| Bookshelf::Bookshelf | ( | QWidget * | parent | ) | [explicit] |
Definition at line 49 of file bookshelf.cpp.
Member Function Documentation
| void Bookshelf::changeColor | ( | ) | [protected, slot] |
Definition at line 637 of file bookshelf.cpp.
| void Bookshelf::contextMenuEvent | ( | QContextMenuEvent * | event | ) | [protected, virtual] |
Definition at line 154 of file bookshelf.cpp.
| void Bookshelf::copyLinkAddress | ( | ) | [protected, slot] |
| KJotsBook * Bookshelf::currentBook | ( | void | ) |
Returns a pointer to the currently selected book, or the book that owns the currently selected page.
Definition at line 508 of file bookshelf.cpp.
Returns a representation of the current selection.
Definition at line 611 of file bookshelf.cpp.
| KJotsEntry * Bookshelf::currentEntry | ( | void | ) |
Returns a pointer to the currently selected page.
Definition at line 478 of file bookshelf.cpp.
| KJotsPage * Bookshelf::currentPage | ( | void | ) |
Returns a pointer to the currently selected page.
Definition at line 492 of file bookshelf.cpp.
| KJotsBook * Bookshelf::currentTopLevelBook | ( | void | ) |
Returns a pointer to the toplevel book that owns the currently selected book or page.
Definition at line 531 of file bookshelf.cpp.
| void Bookshelf::DelayedInitialization | ( | KActionCollection * | actionCollection | ) |
Definition at line 70 of file bookshelf.cpp.
| void Bookshelf::dragEnterEvent | ( | QDragEnterEvent * | event | ) | [protected, virtual] |
Definition at line 306 of file bookshelf.cpp.
| void Bookshelf::dragMoveEvent | ( | QDragMoveEvent * | event | ) | [protected, virtual] |
Definition at line 317 of file bookshelf.cpp.
| bool Bookshelf::dropMimeData | ( | QTreeWidgetItem * | parent, | |
| int | index, | |||
| const QMimeData * | data, | |||
| Qt::DropAction | action | |||
| ) |
| KJotsEntry * Bookshelf::entryFromId | ( | quint64 | id | ) |
Returns a pointer to the KJotsEntry with the given ID or 0 if none matches.
- Parameters:
-
id The ID to look for.
- Todo:
- Should we optimize this by using a container?
Definition at line 218 of file bookshelf.cpp.
| void Bookshelf::entryRenamed | ( | QTreeWidgetItem * | item, | |
| int | ||||
| ) | [protected, slot] |
Definition at line 465 of file bookshelf.cpp.
| void Bookshelf::itemWasCollapsed | ( | QTreeWidgetItem * | item | ) | [protected, slot] |
| void Bookshelf::itemWasExpanded | ( | QTreeWidgetItem * | item | ) | [protected, slot] |
| void Bookshelf::jumpToEntry | ( | QTreeWidgetItem * | item | ) |
Makes the given entry the new selection in the bookshelf.
- Parameters:
-
item The entry to select.
Definition at line 249 of file bookshelf.cpp.
| void Bookshelf::jumpToId | ( | quint64 | id | ) |
Makes the given ID the new selection in the bookshelf.
- Parameters:
-
id The ID to select.
Definition at line 237 of file bookshelf.cpp.
| void Bookshelf::loadBooks | ( | void | ) | [protected] |
Loads all the books it can find in the appdata directory.
- Warning:
- Needless to say: this should only ever be called once. For reasons surpassing understanding, QTreeWidgetItems do not behave well when you construct a tree without first attaching them to a QTreeWidget. Hopefully, this will be fixed in a future version of Qt. Until then, we attach the books and create them first, then remove them, then reattach them in the correct order.
Definition at line 97 of file bookshelf.cpp.
| QMimeData * Bookshelf::mimeData | ( | const QList< QTreeWidgetItem * > | items | ) | const |
Exports dropped data.
Definition at line 339 of file bookshelf.cpp.
| QStringList Bookshelf::mimeTypes | ( | ) | const |
Indicate the mime types we handle.
Definition at line 299 of file bookshelf.cpp.
| void Bookshelf::nextBook | ( | ) | [slot] |
| void Bookshelf::nextPage | ( | ) | [slot] |
| void Bookshelf::onHeaderClick | ( | int | ) | [slot] |
Definition at line 761 of file bookshelf.cpp.
| void Bookshelf::prepareForExit | ( | void | ) |
Runs just before KJots is closed. Save your stuff!
Definition at line 192 of file bookshelf.cpp.
| void Bookshelf::prevBook | ( | ) | [slot] |
Moves to the previous book before the current selection.
Definition at line 681 of file bookshelf.cpp.
| void Bookshelf::prevPage | ( | ) | [slot] |
Moves to the previous page before the current selection.
Definition at line 734 of file bookshelf.cpp.
| void Bookshelf::remove | ( | QTreeWidgetItem * | item | ) |
Remove the given entry from the bookshelf and delete it if necessary.
Definition at line 263 of file bookshelf.cpp.
| QList< KJotsEntry * > Bookshelf::selected | ( | void | ) |
Return everything selected, but don't let a page of a book and a book both be in the list because then there would be duplication.
Definition at line 587 of file bookshelf.cpp.
| void Bookshelf::sortBook | ( | QTreeWidgetItem * | book | ) | [protected] |
Definition at line 776 of file bookshelf.cpp.
| Qt::DropActions Bookshelf::supportedDropActions | ( | ) | const |
Indicate the drop types we handle.
Definition at line 291 of file bookshelf.cpp.
Member Data Documentation
Qt::SortOrder Bookshelf::sortOrder [protected] |
Definition at line 81 of file bookshelf.h.
The documentation for this class was generated from the following files:
KDE 4.2 API Reference