Home | History | Annotate | Download | only in views
      1 #ifndef SkViewPriv_DEFINED
      2 #define SkViewPriv_DEFINED
      3 
      4 #include "SkView.h"
      5 #include "SkTagList.h"
      6 
      7 struct Layout_SkTagList : SkTagList {
      8 	SkView::Layout*	fLayout;
      9 
     10 	Layout_SkTagList(SkView::Layout* layout)
     11 		: SkTagList(kViewLayout_SkTagList), fLayout(layout)
     12 	{
     13 		SkASSERT(layout);
     14 		layout->ref();
     15 	}
     16 	virtual ~Layout_SkTagList()
     17 	{
     18 		fLayout->unref();
     19 	}
     20 };
     21 
     22 struct Artist_SkTagList : SkTagList {
     23 	SkView::Artist*	fArtist;
     24 
     25 	Artist_SkTagList(SkView::Artist* artist)
     26 		: SkTagList(kViewArtist_SkTagList), fArtist(artist)
     27 	{
     28 		SkASSERT(artist);
     29 		artist->ref();
     30 	}
     31 	virtual ~Artist_SkTagList()
     32 	{
     33 		fArtist->unref();
     34 	}
     35 };
     36 
     37 #endif
     38 
     39