2 * Copyright 2003-2010, Haiku, Inc. All Rights Reserved.
3 * Copyright 2004-2005 yellowTAB GmbH. All Rights Reserverd.
4 * Copyright 2006 Bernd Korz. All Rights Reserved
5 * Distributed under the terms of the MIT License.
8 * Fernando Francisco de Oliveira
13 * Stephan Aßmus <superstippi@gmx.de>
15 #ifndef IMAGE_FILE_NAVIGATOR_H
16 #define IMAGE_FILE_NAVIGATOR_H
20 #include <Messenger.h>
27 class ImageFileNavigator
{
29 ImageFileNavigator(const entry_ref
& ref
,
30 const BMessenger
& trackerMessenger
);
31 virtual ~ImageFileNavigator();
33 void SetTo(const entry_ref
& ref
, int32 page
= 1,
35 const entry_ref
& CurrentRef() const { return fCurrentRef
; }
37 // The same image file may have multiple pages, TIFF images for
38 // example. The page count is determined at image loading time.
47 bool HasPreviousPage();
48 bool GoToPage(int32 page
);
54 bool HasPreviousFile();
56 bool GetNextFile(const entry_ref
& ref
,
58 bool GetPreviousFile(const entry_ref
& ref
,
59 entry_ref
& previousRef
);
61 bool MoveFileToTrash();
64 Navigator
* fNavigator
;
66 entry_ref fCurrentRef
;
68 // of the image in the file
70 // number of images in the file
73 // Type of image, for use in status bar and caption
78 #endif // IMAGE_FILE_NAVIGATOR_H