Changeset 5826


Ignore:
Timestamp:
May 12, 2008, 10:38:50 PM (14 years ago)
Author:
livings124
Message:

more adjustments to dragging with groups

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/NEWS

    r5824 r5826  
    44http://trac.transmissionbt.com/query?group=component&milestone=1.30
    55- Mac
    6    + Torrents can be dragged to different groups
     6   + Transfers can be dragged to different groups
    77   + Status strings are toggled from the action button (they are no longer clickable)
    88
  • trunk/macosx/Controller.m

    r5825 r5826  
    26102610            if (!item)
    26112611                return NSDragOperationNone;
    2612             else if ([item isKindOfClass: [Torrent class]])
     2612           
     2613            if ([[fDefaults stringForKey: @"Sort"] isEqualToString: SORT_ORDER])
    26132614            {
    2614                 NSDictionary * group = [fTableView parentForItem: item];
    2615                 if ([[fDefaults stringForKey: @"Sort"] isEqualToString: SORT_ORDER])
     2615                if ([item isKindOfClass: [Torrent class]])
     2616                {
     2617                    NSDictionary * group = [fTableView parentForItem: item];
    26162618                    index = [[group objectForKey: @"Torrents"] indexOfObject: item] + 1;
     2619                    item = group;
     2620                }
    26172621                else
    2618                     index = NSOutlineViewDropOnItemIndex;
    2619                 item = group;
     2622                {
     2623                    if (index == NSOutlineViewDropOnItemIndex)
     2624                        index = [[item objectForKey: @"Torrents"] count];
     2625                }
    26202626            }
    26212627            else
    26222628            {
    2623                 if ([[fDefaults stringForKey: @"Sort"] isEqualToString: SORT_ORDER])
    2624                     index = [[item objectForKey: @"Torrents"] count];
    2625                 else
    2626                     index = NSOutlineViewDropOnItemIndex;
     2629                if ([item isKindOfClass: [Torrent class]])
     2630                    item = [fTableView parentForItem: item];
     2631               
     2632                index = NSOutlineViewDropOnItemIndex;
    26272633            }
    26282634        }
Note: See TracChangeset for help on using the changeset viewer.