[Bug 156186] New: Sorting of albums other than alphabetically

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

[Bug 156186] New: Sorting of albums other than alphabetically

chrisisbd
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=156186         
           Summary: Sorting of albums other than alphabetically
           Product: digikam
           Version: 0.9.2
          Platform: Fedora RPMs
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: wishlist
          Priority: NOR
         Component: general
        AssignedTo: digikam-devel kde org
        ReportedBy: chris isbd co uk


Version:           0.9.2 (using KDE 3.5.8)
Installed from:    Fedora RPMs
OS:                Linux

It would be good to be able to specify different sort orders for albums/sub-directories so that, for example, they could be sorted by date rather than alphabetically.

It would also be good to be able to specify album/sub-folder order 'by hand' as it were.  For example if I have an album called 1960 which has sub-directories "Spring - Barnet", "Easter - Cottage", "Summer - Cottage", "Autumn" I'd like to be able to list them in the following order in the 1960 album:-

    Easter - Cottage
    Spring - Barnet
    Summer - Cottage
    Autumn

I.e. I'd like to be able to drag and drop the sub-directories to my choice of place in the album regardless of their actual creation date or alphabetical order (like you sort bookmarks in Firefox for example).
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 156186] Sorting of albums other than alphabetically

Arnd Baecker
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=156186         
arnd.baecker web de changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|general                     |Albums GUI
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 156186] Sorting of albums other than alphabetically

chrisisbd
In reply to this post by chrisisbd
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=156186         




------- Additional Comments From chris isbd co uk  2008-07-04 23:27 -------
My ideal would be to sort albums by the album properties date in the folder view of albums.  This would allow albums given month names (for example) to be shown in chronological order rather than alphabetical order as at present.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 156186] Sorting of albums other than alphabetically

chrisisbd
In reply to this post by chrisisbd
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=156186         




------- Additional Comments From chris isbd co uk  2008-07-10 22:34 -------
As requested my patch to do this is as follows:-

In albumfolderview.cpp, method AlbumFolderViewItem::compare(QListViewItem *i, int col, bool ascending):-

Lines 215-218 were:-

    if (!m_groupItem || m_year == 0 || m_month == 0)
    {
        return QListViewItem::compare(i, col, ascending);
    }

Change them to:-

    if (!m_groupItem || m_year == 0 || m_month == 0)
    {
        PAlbum * myalbum = album();

        if (!myalbum)
            return 0;

        QDate myDate = myalbum->date();

        AlbumFolderViewItem* thatItem = dynamic_cast<AlbumFolderViewItem*>(i);
        if (!thatItem)
            return 0;
        PAlbum * thatAlbum = thatItem->album();
        if (!thatAlbum)
            return 0;
        QDate thatDate = thatAlbum->date();

        if (myDate == thatDate)
            return 0;
        else if (myDate > thatDate)
            return 1;
        else
            return -1;
    }

Obviously to make this switchable from original (alphabetical) sort to my new chrinological sort it needs a menu option and an if/else block to choose the new or old code.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 156186] Sorting of albums other than alphabetically

Arnd Baecker
In reply to this post by chrisisbd
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=156186         




------- Additional Comments From arnd.baecker web de  2008-07-11 09:53 -------
Created an attachment (id=26034)
 --> (http://bugs.kde.org/attachment.cgi?id=26034&action=view)
patch as in #c2

The patch works fine for me (and: I really like that behaviour!!).

There is one additional thing: if the dates are equal, I would propose
to use the usual alphabetical sorting.
(The dates can be excatly equal, when one uses the GUI...)
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 156186] Sorting of albums other than alphabetically

chrisisbd
In reply to this post by chrisisbd
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=156186         




------- Additional Comments From chris isbd co uk  2008-07-11 12:30 -------
Yes, that's a good point, and it would be very easy to do it.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel