PageLayoutControlEvents.h
// Copyright 2010 ESRI // // All rights reserved under the copyright laws of the United States // and applicable international laws, treaties, and conventions. // // You may freely redistribute and use this sample code, with or // without modification, provided you include the original copyright // notice and use restrictions. // // See the use restrictions. // #ifndef __PAGELAYOUTCONTROLEVENTS_H_ #define __PAGELAYOUTCONTROLEVENTS_H_ // Motif Headers #define String esriXString #define Time esriXTime #define Cursor esriXCursor #define Object esriXObject #define ObjectClass esriXObjectClass #include <Xm/Xm.h> #include <Xm/MainW.h> #include <Xm/Form.h> #include <Xm/Text.h> #undef String #undef Time #undef Cursor #undef Object #undef ObjectClass // ArcObjects Headers // Engine #include <ArcSDK.h> // Controls #include <Ao/AoControls.h> extern IPageLayoutControlPtr g_ipMainPageLayout; extern IPageLayoutControlPtr g_ipOverviewPageLayout; extern Widget g_loadText; extern IFillSymbolPtr g_ipFillSymbol; class PageLayoutControlEvents : public IPageLayoutControlEventsHelper { public: // IUnknown HRESULT __stdcall QueryInterface(REFIID riid, void** ppvObj) { return S_OK; } ULONG __stdcall AddRef() { return 0; } ULONG __stdcall Release() { return 0; } // IPageLayoutControlEvents void OnAfterDraw(VARIANT display, long viewDrawPhase); void OnAfterScreenDraw(long hdc); void OnBeforeScreenDraw(long hdc); void OnDoubleClick(long button, long shift, long x, long y, double mapX, double mapY); void OnExtentUpdated(VARIANT displayTransformation, VARIANT_BOOL sizeChanged, VARIANT newEnvelope); void OnFullExtentUpdated(VARIANT displayTransformation, VARIANT newEnvelope); void OnKeyDown(long keyCode, long shift); void OnKeyUp(long keyCode, long shift); void OnFocusMapChanged(); void OnPageLayoutReplaced(VARIANT newPageLayout); void OnPageSizeChanged(); void OnMouseDown(long button, long shift, long x, long y, double mapX, double mapY); void OnMouseMove(long button, long shift, long x, long y, double mapX, double mapY); void OnMouseUp(long button, long shift, long x, long y, double mapX, double mapY); void OnOleDrop(esriControlsDropAction dropAction, VARIANT dataObjectHelper, long* effect, long button, long shift, long x, long y); void OnSelectionChanged(); void OnViewRefreshed(VARIANT ActiveView, long viewDrawPhase, VARIANT layerOrElement, VARIANT envelope); private: HRESULT CreateOverviewSymbol(); }; #endif // __PAGELAYOUTCONTROLEVENTS_H_