summaryrefslogtreecommitdiffstats
path: root/kdejava/koala/org/kde/koala/KRecentDocument.java
diff options
context:
space:
mode:
Diffstat (limited to 'kdejava/koala/org/kde/koala/KRecentDocument.java')
-rw-r--r--kdejava/koala/org/kde/koala/KRecentDocument.java85
1 files changed, 85 insertions, 0 deletions
diff --git a/kdejava/koala/org/kde/koala/KRecentDocument.java b/kdejava/koala/org/kde/koala/KRecentDocument.java
new file mode 100644
index 00000000..93220ea8
--- /dev/null
+++ b/kdejava/koala/org/kde/koala/KRecentDocument.java
@@ -0,0 +1,85 @@
+//Auto-generated by kalyptus. DO NOT EDIT.
+package org.kde.koala;
+
+import org.kde.qt.Qt;
+import org.kde.qt.QtSupport;
+import java.util.ArrayList;
+
+/**
+
+ Manage the "Recent Document Menu" entries displayed by
+ applications such as Kicker and Konqueror.
+ These entries are automatically generated .desktop files pointing
+ to the current application and document. You should call the
+ static add() method whenever the user opens or saves a new
+ document if you want it to show up in the menu.
+ You don't have to worry about this if you are using any
+ KFileDialog derived class to open and save documents, as it
+ already calls this class. User defined limits on the maximum
+ number of documents to save, etc... are all automatically handled.
+ @author Daniel M. Duley <mosfet@kde.org>
+
+ @short Manage the "Recent Document Menu" entries displayed by applications such as Kicker and Konqueror.
+
+*/
+public class KRecentDocument implements QtSupport {
+ private long _qt;
+ private boolean _allocatedInJavaWorld = true;
+ protected KRecentDocument(Class dummy){}
+
+ public KRecentDocument() {
+ newKRecentDocument();
+ }
+ private native void newKRecentDocument();
+ /**
+ Return a list of absolute paths to recent document .desktop files,
+ sorted by date.
+ @short
+ */
+ public static native ArrayList recentDocuments();
+ /**
+ Add a new item to the Recent Document menu.
+ @param url The url to add.
+ @short Add a new item to the Recent Document menu.
+ */
+ public static native void add(KURL url);
+ /**
+ Add a new item to the Recent Document menu, specifying the application to open it with.
+ The above add() method uses argv[0] for the app name, which isn't always flexible enough.
+ This method is used when an application launches another one to open a document.
+ @param url The url to add.
+ @param desktopEntryName The desktopEntryName of the service to use for opening this document.
+ @short Add a new item to the Recent Document menu, specifying the application to open it with.
+ */
+ public static native void add(KURL url, String desktopEntryName);
+ /**
+ Add a new item to the Recent Document menu. Calls add( url ).
+ @param documentStr The full path to the document or URL to add.
+ @param isURL Set to <code>true</code> if <code>documentStr</code> is an URL and not a local file path.
+ @short
+ */
+ public static native void add(String documentStr, boolean isURL);
+ public static native void add(String documentStr);
+ /**
+ Clear the recent document menu of all entries.
+ @short Clear the recent document menu of all entries.
+ */
+ public static native void clear();
+ /**
+ Returns the maximum amount of recent document entries allowed.
+ @short Returns the maximum amount of recent document entries allowed.
+ */
+ public static native int maximumItems();
+ /**
+ Returns the path to the directory where recent document .desktop files
+ are stored.
+ @short Returns the path to the directory where recent document .
+ */
+ public static native String recentDocumentDirectory();
+ /** Deletes the wrapped C++ instance */
+ protected native void finalize() throws InternalError;
+ /** Delete the wrapped C++ instance ahead of finalize() */
+ public native void dispose();
+ /** Has the wrapped C++ instance been deleted? */
+ public native boolean isDisposed();
+}