Adobe.com
Contents Suites Classes Class Index Member Index

AIPanel.h

Go to the documentation of this file.
00001 /*************************************************************************
00002 *
00003 *ADOBE SYSTEMS INCORPORATED
00004 * Copyright 2016 Adobe Systems Incorporated
00005 * All Rights Reserved.
00006 *
00007 *NOTICE:  Adobe permits you to use, modify, and distribute this file in accordance with the 
00008 *terms of the Adobe license agreement accompanying it.  If you have received this file from a 
00009 *source other than Adobe, then your use, modification, or distribution of it requires the prior 
00010 *written permission of Adobe.
00011 *
00012 **************************************************************************/
00013 
00014 #ifndef __AIPANEL_H__
00015 #define __AIPANEL_H__
00016 
00017 #include "AITypes.h"
00018 #include "IAIUnicodeString.h"
00019 #include "IAIAutoBuffer.h"
00022 /*******************************************************************************
00023 **
00024 **      Constants
00025 **
00026 **/
00027 
00028 #define kAIPanelSuite                                   "AI Panel Suite"
00029 #define kAIPanelSuiteVersion4                   AIAPI_VERSION(4)
00030 #define kAIPanelSuiteVersion                    kAIPanelSuiteVersion4
00031 #define kAIPanelVersion                                 kAIPanelSuiteVersion
00032 
00033 
00034 #define kAIPanelFlyoutMenuSuite                         "AI Panel Flyout Menu Suite"
00035 #define kAIPanelFlyoutMenuSuiteVersion2         AIAPI_VERSION(2)
00036 #define kAIPanelFlyoutMenuSuiteVersion          kAIPanelFlyoutMenuSuiteVersion2
00037 #define kAIPanelFlyoutMenuVersion                       kAIPanelFlyoutMenuSuiteVersion
00038 
00039 /*******************************************************************************
00040 **
00041 ** Types
00042 **
00043 **/
00044 #ifdef WIN_ENV
00045         typedef HWND AIPanelPlatformWindow;
00046 #elif defined(MAC_ENV)
00047     #ifdef __OBJC__
00048         @class NSView;
00049         typedef NSView* AIPanelPlatformWindow;
00050     #else
00051     typedef void*       AIPanelPlatformWindow;
00052     #endif
00053 #else
00054 #error unknown configuration
00055 #endif
00056 
00058 typedef struct _opaque_AIPanel* AIPanelRef;
00059 
00061 typedef struct _opaque_AIPanelFlyoutMenu* AIPanelFlyoutMenuRef;
00062 
00065 enum {
00066         kAIPanelFlyoutMenuItemMark_NONE,
00067         kAIPanelFlyoutMenuItemMark_CHECK,
00068         kAIPanelFlyoutMenuItemMark_BULLET,
00069         kAIPanelFlyoutMenuItemMark_DASH
00070 };
00071 
00074 typedef ai::uint32 AIPanelFlyoutMenuItemMark;
00075 
00078 typedef void* AIPanelUserData;
00079 
00084 typedef void AIAPI (*AIPanelFlyoutMenuPreVisibilityProc)(AIPanelRef inPanel);
00085 
00091 typedef void AIAPI (*AIPanelFlyoutMenuProc)(AIPanelRef inPanel, ai::uint32 itemID);
00092 
00098 typedef void AIAPI (*AIPanelVisibilityChangedNotifyProc)(AIPanelRef inPanel, AIBoolean isVisible);
00099 
00104 typedef void AIAPI (*AIPanelSizeChangedNotifyProc)(AIPanelRef inPanel);
00105 
00111 typedef void AIAPI (*AIPanelStateChangedNotifyProc)(AIPanelRef inPanel, ai::int16 newState);
00112 
00117 typedef void AIAPI (*AIPanelClosedNotifyProc)(AIPanelRef inPanel);
00118 
00119 
00120 /************************************************************************/
00122 /************************************************************************/
00126 #define kAIInvalidPanelRef                      'INVD'
00127 
00128 
00129 
00130 /*******************************************************************************
00131 **
00132 **      Suite
00133 **
00134 **/
00135 
00143 struct AIPanelSuite{
00144 
00156         AIAPI AIErr     (*Create)(SPPluginRef inPluginRef, const ai::UnicodeString& inID, const ai::UnicodeString& inTitle,
00157                                                         ai::int16 inStateCount, const AISize& inMinSize, AIBoolean isResizable,
00158                                                         AIPanelFlyoutMenuRef inFlyoutMenu, AIPanelUserData inUserData, AIPanelRef& outPanel);
00159 
00160 
00165         AIAPI AIErr     (*Destroy)(AIPanelRef inPanel);
00166 
00167 
00172         AIAPI AIErr (*GetPlatformWindow)(AIPanelRef inPanel, AIPanelPlatformWindow& outPlatformWindow);
00173 
00174 
00180         AIAPI AIErr     (*Show)(AIPanelRef inPanel, AIBoolean inShow);
00181 
00182 
00183 
00191         AIAPI AIErr (*IsShown)(AIPanelRef inPanel, AIBoolean& outIsShown);
00192 
00193 
00199         AIAPI AIErr     (*GetUserData)(AIPanelRef inPanel, AIPanelUserData& outUserData);
00200 
00201 
00207         AIAPI AIErr     (*SetUserData)(AIPanelRef inPanel, AIPanelUserData inUserData);
00208 
00209 
00214         AIAPI AIErr     (*SetTitle)(AIPanelRef inPanel, const ai::UnicodeString& inTitle);
00215 
00216 
00221         AIAPI AIErr     (*GetTitle)(AIPanelRef inPanel, ai::UnicodeString& outTitle);
00222 
00223 
00231         AIAPI AIErr     (*SetIcon)(AIPanelRef inPanel, const ai::AutoBuffer<const ai::uint8*>& inPNGData, const ai::AutoBuffer<ai::uint32>& inDataSize,
00232                                                         const ai::AutoBuffer<const ai::uint8*>& inPNGDarkData, const ai::AutoBuffer<ai::uint32>& inDarkDataSize);
00233 
00234 
00242         AIAPI AIErr     (*SetIconResourceID)(AIPanelRef inPanel, const ai::AutoBuffer<ai::uint32>& iconResId, const ai::AutoBuffer<ai::uint32>& darkIconResId);
00243 
00249     AIAPI AIErr (*SetSVGIconResourceID)(AIPanelRef inPanel, ai::uint32 iconResId, ai::uint32 darkIconResId);
00250     
00251 
00257         AIAPI AIErr     (*GetSize)(AIPanelRef inPanel, AISize& outSize);
00258 
00259 
00264         AIAPI AIErr     (*SetMinimumSize)(AIPanelRef inPanel, const AISize& inMinimumSize);
00265 
00266 
00271         AIAPI AIErr     (*GetMinimumSize)(AIPanelRef inPanel, AISize& outMinimumSize);
00272 
00273 
00278         AIAPI AIErr     (*SetMaximumSize)(AIPanelRef inPanel, const AISize& inMaximumSize);
00279 
00280 
00285         AIAPI AIErr     (*GetMaximumSize)(AIPanelRef inPanel, AISize& outMaximumSize);
00286 
00287 
00296         AIAPI AIErr     (*SetPreferredSizes)(AIPanelRef inPanel, const AISize& inPreferredSize);
00297 
00298 
00306         AIAPI AIErr     (*SetSizes)(AIPanelRef inPanel, const AISize& inMinimumSize, const AISize& inPreferredUnconstrainedSize,
00307                                                         const AISize& inPreferredConstrainedSize, const AISize& inMaximumSize);
00308 
00309 
00318         AIAPI AIErr     (*SetSize)(AIPanelRef inPanel, const AISize& inSize);
00319 
00320 
00326         AIAPI AIErr (*GetPreferredConstrainedSize)(AIPanelRef inPanel, AISize& outPreferredConstrainedSize);
00327 
00328 
00334         AIAPI AIErr (*GetPreferredUnconstrainedSize)(AIPanelRef inPanel, AISize& outPreferredUnconstrainedSize);
00335 
00336 
00341         AIAPI AIErr     (*SetCurrentState)(AIPanelRef inPanel, ai::int16 inCurrentState);
00342 
00343 
00348         AIAPI AIErr     (*GetCurrentState)(AIPanelRef inPanel, ai::int16& outCurrentState);
00349 
00350 
00355         AIAPI AIErr     (*SetStateCount)(AIPanelRef inPanel, ai::int16 inStateCount);
00356 
00357 
00362         AIAPI AIErr     (*GetStateCount)(AIPanelRef inPanel, ai::int16& outStateCount);
00363 
00364 
00372         AIAPI AIErr     (*SetVerticalStepSize)(AIPanelRef inPanel, AIReal inStepSize);
00373 
00374 
00379         AIAPI AIErr     (*GetVerticalStepSize)(AIPanelRef inPanel, AIReal& outStepSize);
00380 
00381 
00387         AIAPI AIErr     (*SetFlyoutMenu)(AIPanelRef inPanel, AIPanelFlyoutMenuRef inFlyoutMenu);
00388 
00389 
00395         AIAPI AIErr     (*GetFlyoutMenu)(AIPanelRef inPanel, AIPanelFlyoutMenuRef& outFlyoutMenu);
00396 
00397 
00405         AIAPI AIErr (*IsMinimized)(AIPanelRef inPanel, AIBoolean& outIsMinimized);
00406 
00407 
00413         AIAPI AIErr (*ChangeIsMinimized)(AIPanelRef inPanel, AIBoolean inIsMinimized);
00414 
00415 
00422         AIAPI AIErr     (*Move)(AIPanelRef inPanel, AIPoint inPoint);
00423 
00424 
00429         AIAPI AIErr (*SetFlyoutMenuPreVisibilityProc)(AIPanelRef inPanel, AIPanelFlyoutMenuPreVisibilityProc inFlyoutMenuPreVisProc);
00430 
00431 
00436         AIAPI AIErr (*SetFlyoutMenuProc)(AIPanelRef inPanel, AIPanelFlyoutMenuProc inFlyoutMenuProc);
00437 
00438 
00443         AIAPI AIErr (*SetVisibilityChangedNotifyProc)(AIPanelRef inPanel, AIPanelVisibilityChangedNotifyProc inVisibilityChangedNotifyProc);
00444 
00445 
00450         AIAPI AIErr (*SetSizeChangedNotifyProc)(AIPanelRef inPanel, AIPanelSizeChangedNotifyProc inSizeChangedNotifyProc);
00451 
00452 
00457         AIAPI AIErr (*SetStateChangedNotifyProc)(AIPanelRef inPanel, AIPanelStateChangedNotifyProc inStateChangedNotifyProc);
00458 
00459 
00464         AIAPI AIErr (*SetClosedNotifyProc)(AIPanelRef inPanel, AIPanelClosedNotifyProc inPanelClosedNotifyProc);
00465 
00470         AIAPI AIErr(*GetPosition)(AIPanelRef inPanelRef, AIRealRect &outRect);
00471 };
00472 
00473 
00474 
00475 
00476 /*******************************************************************************
00477 **
00478 **      Suite
00479 **
00480 **/
00481 
00489 struct AIPanelFlyoutMenuSuite{
00490 
00495         AIAPI AIErr     (*Create)(AIPanelFlyoutMenuRef& outFlyOutMenu);
00496 
00497 
00502         AIAPI AIErr     (*Destroy)(AIPanelFlyoutMenuRef inFlyOutMenu);
00503 
00504 
00509         AIAPI AIErr     (*Size)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32& outSize);
00510 
00511 
00517         AIAPI AIErr     (*AppendItem)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inNewItemID, const ai::UnicodeString& inItemText);
00518 
00519 
00524         AIAPI AIErr     (*AppendSeparator)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inNewItemID);
00525 
00526 
00533         AIAPI AIErr     (*InsertItem)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inBeforeItemID, ai::uint32 inNewItemID, const ai::UnicodeString& inItemText);
00534 
00535 
00542         AIAPI AIErr     (*InsertSeparator)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inBeforeItemID, ai::uint32 inNewItemID);
00543 
00544 
00549         AIAPI AIErr     (*RemoveItem)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemID);
00550 
00551 
00557         AIAPI AIErr     (*SetItemEnabled)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemID, AIBoolean inEnabled);
00558 
00559 
00565         AIAPI AIErr     (*GetItemEnabled)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemID, AIBoolean& outEnabled);
00566 
00567 
00573         AIAPI AIErr     (*SetItemMark)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemID, AIPanelFlyoutMenuItemMark inItemMark);
00574 
00575 
00581         AIAPI AIErr     (*GetItemMark)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemID, AIPanelFlyoutMenuItemMark& outItemMark);
00582 
00583 
00589         AIAPI AIErr     (*SetItemText)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemID, const ai::UnicodeString& inItemText);
00590 
00591 
00597         AIAPI AIErr     (*GetItemText)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemID, ai::UnicodeString& outItemText);
00598 
00599 
00606         AIAPI AIErr     (*IsItemSeparator)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemIndex, AIBoolean& outIsItemSeparator);
00607 
00608 
00614         AIAPI AIErr     (*SetItemSubMenu)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemID, AIPanelFlyoutMenuRef inSubMenu);
00615 
00616 
00622         AIAPI AIErr     (*GetItemSubMenu)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemID, AIPanelFlyoutMenuRef& outSubMenu);
00623 
00624 
00629         AIAPI AIErr     (*DetachItemSubMenu)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemID);
00630 
00636         AIAPI AIErr     (*SetItemID)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemIndex, ai::uint32 inNewItemID);
00637 
00643         AIAPI AIErr     (*GetItemID)(AIPanelFlyoutMenuRef inFlyOutMenu, ai::uint32 inItemIndex, ai::uint32& outItemID);
00644 };
00645 
00646 
00647 #endif


Contents Suites Classes Class Index Member Index
Adobe Solutions Network
 
Copyright © 2014 Adobe Systems Incorporated. All rights reserved.
Terms of Use Online Privacy Policy Adobe and accessibility Avoid software piracy Permissions and Trademarks