1 /* 2 * Copyright 2024, Andrew Lindesay <apl@lindesay.co.nz>. 3 * All rights reserved. Distributed under the terms of the MIT License. 4 */ 5 #ifndef BITMAP_HOLDER_H 6 #define BITMAP_HOLDER_H 7 8 9 #include <Bitmap.h> 10 #include <Referenceable.h> 11 12 #include "HaikuDepotConstants.h" 13 14 15 /*! This class only serves as a holder for a bitmap that is referencable. 16 It is used for carrying icon images as well as icons for packages. 17 */ 18 19 class BitmapHolder : public BReferenceable 20 { 21 public: 22 BitmapHolder(const BBitmap* bitmap); 23 virtual ~BitmapHolder(); 24 25 const BBitmap* Bitmap() const; 26 27 private: 28 const BBitmap* fBitmap; 29 }; 30 31 32 typedef BReference<BitmapHolder> BitmapHolderRef; 33 34 35 #endif // BITMAP_HOLDER_H 36