[Kde-imaging] kdeextragear-libs-1
Renchi Raju
renchi at pooh.tam.uiuc.edu
Fri Sep 10 15:53:00 CEST 2004
CVS commit by pahlibar:
* removed AlbumEQDir feature from interface
* added new virtual function to imagecollection(shared) isDirectory().
base implementation returns false.
CCMAIL: kde-imaging at kde.org
M +0 -4 kipi-plugins/helloworld/plugin_helloworld.cpp 1.17
M +15 -0 libkipi/libkipi/imagecollection.cpp 1.16
M +1 -0 libkipi/libkipi/imagecollection.h 1.14
M +5 -0 libkipi/libkipi/imagecollectionshared.cpp 1.11
M +1 -0 libkipi/libkipi/imagecollectionshared.h 1.12
M +0 -7 libkipi/libkipi/interface.cpp 1.22
M +8 -9 libkipi/libkipi/interface.h 1.22
--- kdeextragear-libs-1/kipi-plugins/helloworld/plugin_helloworld.cpp #1.16:1.17
@@ -90,8 +90,4 @@ void Plugin_HelloWorld::slotActivate()
<< endl;
- kdDebug( 51000 ) << " AlbumEQDir: "
- << (m_interface->hasFeature( KIPI::AlbumEQDir ) ? "Yes" : "No")
- << endl;
-
kdDebug( 51000 ) << " ImagesHasComments: "
<< (m_interface->hasFeature( KIPI::ImagesHasComments ) ? "Yes" : "No")
--- kdeextragear-libs-1/libkipi/libkipi/imagecollection.cpp #1.15:1.16
@@ -223,4 +223,19 @@ QString KIPI::ImageCollection::uploadRoo
}
+/*
+ Returns whether an imagecollection is a physical folder on the filesystem
+ or not. Its important to check this, if your plugin needs to do folder
+ based operations for an imagecollection
+*/
+bool KIPI::ImageCollection::isDirectory() const
+{
+ if ( _data )
+ return _data->isDirectory();
+ else {
+ printNullError();
+ return false;
+ }
+}
+
bool KIPI::ImageCollection::isValid() const
{
--- kdeextragear-libs-1/libkipi/libkipi/imagecollection.h #1.13:1.14
@@ -50,4 +50,5 @@ namespace KIPI
KURL uploadRoot() const;
QString uploadRootName() const;
+ bool isDirectory() const;
bool isValid() const;
--- kdeextragear-libs-1/libkipi/libkipi/imagecollectionshared.cpp #1.10:1.11
@@ -82,4 +82,9 @@ QString KIPI::ImageCollectionShared::upl
}
+bool KIPI::ImageCollectionShared::isDirectory()
+{
+ return false;
+}
+
QString KIPI::ImageCollectionShared::comment()
{
--- kdeextragear-libs-1/libkipi/libkipi/imagecollectionshared.h #1.11:1.12
@@ -53,4 +53,5 @@ namespace KIPI
virtual KURL uploadRoot();
virtual QString uploadRootName();
+ virtual bool isDirectory();
virtual bool operator==(ImageCollectionShared&);
--- kdeextragear-libs-1/libkipi/libkipi/interface.cpp #1.21:1.22
@@ -47,9 +47,4 @@
/*!
- \enum KIPI::AlbumEQDir
- This feature specifies that each album is equal to a directory for the host application.
- */
-
-/*!
\enum KIPI::ImagesHasComments
This feature specifies that images in the host application has descriptions associated to them.
@@ -131,6 +126,4 @@ bool KIPI::Interface::hasFeature( const
if ( feature == "AlbumsHaveComments" )
return hasFeature( KIPI::AlbumsHaveComments );
- else if ( feature == "AlbumEQDir" )
- return hasFeature( KIPI::AlbumEQDir );
else if ( feature == "ImagesHasComments" )
return hasFeature( KIPI::ImagesHasComments );
--- kdeextragear-libs-1/libkipi/libkipi/interface.h #1.21:1.22
@@ -42,13 +42,12 @@ namespace KIPI
enum Features {
AlbumsHaveComments = 0x0001,
- AlbumEQDir = 0x0002,
- ImagesHasComments = 0x0004,
- ImagesHasTime = 0x0008,
- SupportsDateRanges = 0x0010,
- AcceptNewImages = 0x0020,
- ImageTitlesWritable = 0x0040,
- AlbumsHaveCategory = 0x0060,
- AlbumsHaveCreationDate = 0x0080,
- AlbumsUseFirstImagePreview = 0x0100
+ ImagesHasComments = 0x0002,
+ ImagesHasTime = 0x0004,
+ SupportsDateRanges = 0x0008,
+ AcceptNewImages = 0x0010,
+ ImageTitlesWritable = 0x0020,
+ AlbumsHaveCategory = 0x0040,
+ AlbumsHaveCreationDate = 0x0060,
+ AlbumsUseFirstImagePreview = 0x0080
// When adding new items, remember to update "hasFeature( const QString& feature )"
// and the hello world plugin.
More information about the Kde-imaging
mailing list