/[gnustep]/gnustep/usr-apps/gworkspace/Viewers/SmallIconsViewer/SmallIconsPanel.h
ViewVC logotype

Contents of /gnustep/usr-apps/gworkspace/Viewers/SmallIconsViewer/SmallIconsPanel.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Wed Aug 27 10:13:53 2003 UTC (20 years, 7 months ago) by esersale
Branch: MAIN
Changes since 1.1: +19 -18 lines
File MIME type: text/plain
*** empty log message ***

1 /* SmallIconsPanel.h
2 *
3 * Copyright (C) 2003 Free Software Foundation, Inc.
4 *
5 * Author: Enrico Sersale <enrico@imago.ro>
6 * Date: August 2001
7 *
8 * This file is part of the GNUstep GWorkspace application
9 *
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
14 *
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
19 *
20 * You should have received a copy of the GNU General Public License
21 * along with this program; if not, write to the Free Software
22 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
23 */
24
25
26 #ifndef SMALLICONSPANEL_H
27 #define SMALLICONSPANEL_H
28
29 #include <AppKit/NSView.h>
30
31 @class NSString;
32 @class NSMutableString;
33 @class NSArray;
34 @class NSMutableArray;
35 @class NSNotification;
36 @class NSFileManager;
37 @class SmallIcon;
38
39 @interface SmallIconsPanel : NSView
40 {
41 id delegate;
42 id gworkspace;
43 NSString *currentPath;
44
45 NSMutableArray *icons;
46 NSImage *verticalImage;
47 NSImage *horizontalImage;
48
49 BOOL isDragTarget;
50 BOOL isShiftClick;
51 BOOL selectInProgress;
52 int cellsWidth;
53
54 BOOL contestualMenu;
55
56 NSString *charBuffer;
57 NSTimeInterval lastKeyPressed;
58
59 SEL currSelectionSel;
60 IMP currSelection;
61
62 NSFileManager *fm;
63 }
64
65 - (id)initAtPath:(NSString *)path
66 delegate:(id)adelegate;
67
68 - (void)setPath:(NSString *)path;
69 - (void)setCurrentSelection;
70 - (void)reloadFromPath:(NSString *)path;
71 - (NSArray *)checkHiddenFiles:(NSArray *)files atPath:(NSString *)path;
72 - (void)makeFileIcons;
73 - (void)sortIcons;
74
75 - (void)tile;
76 - (void)scrollFirstIconToVisible;
77 - (void)scrollToVisibleIconsWithPaths:(NSArray *)paths;
78
79 - (NSString *)currentPath;
80 - (BOOL)isOnBasePath:(NSString *)bpath withFiles:(NSArray *)files;
81 - (NSArray *)currentSelection;
82 - (SmallIcon *)iconWithPath:(NSString *)path;
83 - (NSArray *)iconsWithPaths:(NSArray *)paths;
84 - (SmallIcon *)iconWithNamePrefix:(NSString *)prefix inRange:(NSRange)range;
85 - (NSPoint)locationOfIconWithName:(NSString *)name;
86
87 - (void)selectIconWithPath:(NSString *)path;
88 - (void)selectIconsWithPaths:(NSArray *)paths;
89 - (void)selectIconInPrevLine;
90 - (void)selectIconInNextLine;
91 - (void)selectPrevIcon;
92 - (void)selectNextIcon;
93 - (void)selectAllIcons;
94 - (void)unselectOtherIcons:(id)anIcon;
95 - (void)extendSelectionWithDimmedFiles:(NSArray *)files
96 startingAtPath:(NSString *)bpath;
97 - (void)openSelectionWithApp:(id)sender;
98 - (void)openSelectionWith:(id)sender;
99
100 - (void)addIconWithPath:(NSString *)iconpath dimmed:(BOOL)isdimmed;
101 - (void)addIconsWithPaths:(NSArray *)iconpaths;
102 - (void)addIconsWithNames:(NSArray *)names dimmed:(BOOL)isdimmed;
103 - (void)removeIcon:(id)anIcon;
104 - (void)removeIconsWithNames:(NSArray *)names;
105
106 - (void)lockIconsWithNames:(NSArray *)names;
107 - (void)unLockIconsWithNames:(NSArray *)names;
108 - (void)lockAllIcons;
109 - (void)unLockAllIcons;
110
111 - (void)setLabelRectOfIcon:(id)anIcon;
112 - (int)cellsWidth;
113 - (void)cellsWidthChanged:(NSNotification *)notification;
114
115 - (void)setShiftClick:(BOOL)value;
116
117 - (void)openCurrentSelection:(NSArray *)paths newViewer:(BOOL)newv;
118
119 - (id)delegate;
120
121 - (void)setDelegate:(id)anObject;
122
123 @end
124
125 @interface SmallIconsPanel (DraggingDestination)
126
127 - (unsigned int)draggingEntered:(id <NSDraggingInfo>)sender;
128
129 - (unsigned int)draggingUpdated:(id <NSDraggingInfo>)sender;
130
131 - (void)draggingExited:(id <NSDraggingInfo>)sender;
132
133 - (BOOL)prepareForDragOperation:(id <NSDraggingInfo>)sender;
134
135 - (BOOL)performDragOperation:(id <NSDraggingInfo>)sender;
136
137 - (void)concludeDragOperation:(id <NSDraggingInfo>)sender;
138
139 @end
140
141 //
142 // Methods Implemented by the Delegate
143 //
144
145 @interface NSObject (SmallIconsPanelDelegateMethods)
146
147 - (void)setTheSelectedPaths:(id)paths;
148
149 - (void)setSelectedPathsFromIcons:(id)paths;
150
151 - (void)openTheCurrentSelection:(id)paths newViewer:(BOOL)newv;
152
153 - (int)iconCellsWidth;
154
155 @end
156
157 //
158 // SmallIcon Delegate Methods
159 //
160
161 @interface SmallIconsPanel (SmallIconDelegateMethods)
162
163 - (void)unselectIconsDifferentFrom:(id)aicon;
164
165 - (void)setShiftClickValue:(BOOL)value;
166
167 - (void)setTheCurrentSelection;
168
169 - (NSArray *)getTheCurrentSelection;
170
171 - (void)openTheCurrentSelection:(id)paths newViewer:(BOOL)newv;
172
173 - (id)menuForRightMouseEvent:(NSEvent *)theEvent;
174
175 @end
176
177 #endif // SMALLICONSPANEL_H
178

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26