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 48 of file bookshelf.cpp.
Member Function Documentation
| void Bookshelf::DelayedInitialization | ( | KActionCollection * | actionCollection | ) |
Definition at line 70 of file bookshelf.cpp.
| void Bookshelf::prepareForExit | ( | void | ) |
Runs just before KJots is closed. Save your stuff!
Definition at line 195 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 240 of file bookshelf.cpp.
| void Bookshelf::jumpToEntry | ( | QTreeWidgetItem * | item | ) |
Makes the given entry the new selection in the bookshelf.
- Parameters:
-
item The entry to select.
Definition at line 252 of file bookshelf.cpp.
| 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 221 of file bookshelf.cpp.
| KJotsEntry * Bookshelf::currentEntry | ( | void | ) |
Returns a pointer to the currently selected page.
Definition at line 508 of file bookshelf.cpp.
| KJotsPage * Bookshelf::currentPage | ( | void | ) |
Returns a pointer to the currently selected page.
Definition at line 522 of file bookshelf.cpp.
| KJotsBook * Bookshelf::currentBook | ( | void | ) |
Returns a pointer to the currently selected book, or the book that owns the currently selected page.
Definition at line 538 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 561 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 617 of file bookshelf.cpp.
| void Bookshelf::remove | ( | QTreeWidgetItem * | item | ) |
Remove the given entry from the bookshelf and delete it if necessary.
Definition at line 266 of file bookshelf.cpp.
Returns a representation of the current selection.
Definition at line 641 of file bookshelf.cpp.
| Qt::DropActions Bookshelf::supportedDropActions | ( | ) | const |
Indicate the drop types we handle.
Definition at line 287 of file bookshelf.cpp.
| QStringList Bookshelf::mimeTypes | ( | ) | const |
Indicate the mime types we handle.
Definition at line 295 of file bookshelf.cpp.
| QMimeData * Bookshelf::mimeData | ( | const QList< QTreeWidgetItem * > | items | ) | const |
Exports dropped data.
Definition at line 335 of file bookshelf.cpp.
| bool Bookshelf::dropMimeData | ( | QTreeWidgetItem * | parent, | |
| int | index, | |||
| const QMimeData * | data, | |||
| Qt::DropAction | action | |||
| ) |
| void Bookshelf::onHeaderClick | ( | int | ) | [slot] |
Definition at line 791 of file bookshelf.cpp.
| void Bookshelf::nextBook | ( | ) | [slot] |
| void Bookshelf::prevBook | ( | ) | [slot] |
Moves to the previous book before the current selection.
Definition at line 711 of file bookshelf.cpp.
| void Bookshelf::nextPage | ( | ) | [slot] |
| void Bookshelf::prevPage | ( | ) | [slot] |
Moves to the previous page before the current selection.
Definition at line 764 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 135 of file bookshelf.cpp.
| void Bookshelf::sortBook | ( | QTreeWidgetItem * | book | ) | [protected] |
Definition at line 806 of file bookshelf.cpp.
| void Bookshelf::dragEnterEvent | ( | QDragEnterEvent * | event | ) | [protected, virtual] |
Definition at line 302 of file bookshelf.cpp.
| void Bookshelf::dragMoveEvent | ( | QDragMoveEvent * | event | ) | [protected, virtual] |
Definition at line 313 of file bookshelf.cpp.
| void Bookshelf::entryRenamed | ( | QTreeWidgetItem * | item, | |
| int | ||||
| ) | [protected, slot] |
Definition at line 461 of file bookshelf.cpp.
| void Bookshelf::setContextMenuOptions | ( | ) | [protected, slot] |
Definition at line 471 of file bookshelf.cpp.
| void Bookshelf::itemWasExpanded | ( | QTreeWidgetItem * | item | ) | [protected, slot] |
| void Bookshelf::itemWasCollapsed | ( | QTreeWidgetItem * | item | ) | [protected, slot] |
| void Bookshelf::copyLinkAddress | ( | ) | [protected, slot] |
| void Bookshelf::changeColor | ( | ) | [protected, slot] |
Definition at line 667 of file bookshelf.cpp.
Member Data Documentation
KActionCollection* Bookshelf::pageActionCollection [protected] |
Definition at line 80 of file bookshelf.h.
KActionCollection* Bookshelf::bookActionCollection [protected] |
Definition at line 81 of file bookshelf.h.
KActionCollection* Bookshelf::multiActionCollection [protected] |
Definition at line 82 of file bookshelf.h.
Qt::SortOrder Bookshelf::sortOrder [protected] |
Definition at line 83 of file bookshelf.h.
The documentation for this class was generated from the following files:
KDE 4.0 API Reference