InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
DropDownListControlDataOf.h
1 //========================================================================================
2 //
3 // $File$
4 //
5 // Owner: Michael Burbidge
6 //
7 // $Author$
8 //
9 // $DateTime$
10 //
11 // $Revision$
12 //
13 // $Change$
14 //
15 // Copyright 1997-2010 Adobe Systems Incorporated. All rights reserved.
16 //
17 // NOTICE: Adobe permits you to use, modify, and distribute this file in accordance
18 // with the terms of the Adobe license agreement accompanying it. If you have received
19 // this file from a source other than Adobe, then your use, modification, or
20 // distribution of it requires the prior written permission of Adobe.
21 //
22 //
23 // ADOBE CONFIDENTIAL
24 //
25 //========================================================================================
26 
27 #ifndef __DropDownListControlDataOf_h__
28 #define __DropDownListControlDataOf_h__
29 
30 #include "IListControlDataOf.h"
31 #include "CPMUnknown.h"
32 
33 template <class T>
34 class DropDownListControlDataOf : public CPMUnknown< IListControlDataOf<T> >
35 {
36 public:
38  virtual ~DropDownListControlDataOf();
39 
40  virtual void Add(const T& item, int32 at, bool16 invalidate, bool16 notifyOfChange);
41  virtual void Add(const K2Vector<T>& items, bool16 invalidate, bool16 notifyOfChange);
42  virtual void Remove(int32 index, bool16 invalidate, bool16 notifyOfChange);
43  virtual void Replace(const T& item, int32 index, bool16 invalidate, bool16 notifyOfChange);
44  virtual void Clear(bool16 invalidate, bool16 notifyOfChange);
45 
46  virtual T operator[](int32 index) const;
47  virtual int32 Length() const;
48 
49  virtual void Refresh() const;
50  virtual void Synchronize(SysControl sysControl) const;
51 
52 private:
53  PMString GetString(const T& item) const;
54 
55 private:
56  K2Vector<T> fElements;
57 };
58 
59 #ifdef _INCLUDE_TPP_IN_H_
60  #include "DropDownListControlDataOf.tpp"
61 #endif //_INCLUDE_TPP_IN_H_
62 
63 #endif // __DropDownListControlDataOf_h__