Click here to Skip to main content
15,897,226 members
Articles / Mobile Apps

Window Tabs (WndTabs) Add-In for DevStudio

Rate me:
Please Sign up or sign in to vote.
5.00/5 (37 votes)
11 Jul 2002 366.2K   7.3K   94  
Window and File Management add-in for Visual C++
/***************************************************************************/
/* NOTE:                                                                   */
/* This document is copyright (c) by Oz Solomonovich, and is bound by the  */
/* MIT open source license (www.opensource.org/licenses/mit-license.html). */
/* See License.txt for more information.                                   */
/***************************************************************************/

// WNDTABS SDK - Internal Definitions

#ifndef __WTSDKDEFS_PRIV_H
#define __WTSDKDEFS_PRIV_H

// Commands implemented by the SDK
#define WTSDK_CMD_QUERY_ADDON         "WTSDK_Query_WT_Addon"
#define WTSDK_CMD_TAB_EVENT           "WTSDK_Tab_Event"
#define WTSDK_CMD_EXEC_COMMAND        "WTSDK_Exec_Command"
#define WTSDK_CMD_UI_UPDATE           "WTSDK_UI_Update"
#define WTSDK_CMD_WT_EVENT            "WTSDK_WT_Event"

// SDK support commands implemented by Wndtabs
#define WTSDK_WT_CMD_REGISTER_ADDON   "Register_WT_Addon"
#define WTSDK_WT_CMD_UNREGISTER_ADDON "Unregister_WT_Addon"
#define WTSDK_WT_CMD_GET_CMD_CONTEXT  "Get_Cmd_Context"
#define WTSDK_WT_CMD_FORCE_UPDATE     "Force_Tab_Update"
#define WTSDK_WT_CMD_GET_TAB_GROUP    "Get_Tab_Group"

// SDK error codes
#define WTSDK_ERR_NOTSUPPORTED        -1
#define WTSDK_ERR_GENERALERR          -2
#define WTSDK_ERR_BADPARAM            -3


struct WTSDK_ExportedCommand
{
    UINT    cbSize;     /* set to size of this structure */

    HBITMAP hBmp;
    LPCSTR  pszName;
    int     iCmd;
    WTSDK_UIUpadateFlags UIUpdateFlags;
};


struct WTSDK_AddonInfo
{
public:
    WTSDK_AddonInfo() 
    {   
        memset(this, sizeof(*this), 0); 
        cbSize = sizeof(*this);
    };

    int cbSize;
    int CompatibilityID;

    // name of addin
    const char *                pszAddOnName;

    // == Tab Update Notifiation ==

    // pointer of a function to recieve tab update notifications or NULL
    WTSDK_TabUpdateEvFn *       pTabUpdateEvFn;


    // == Event Notification ==
    WTSDK_EvNotificationFn *    pEvNotificationFn;
    int                         event_mask;

    // == Adding Commands To WndTabs ==

    // command event handler or NULL
    WTSDK_CmdEvFn *             pCmdEvFn;

    // array of pointer to commands (can be NULL if pCmdUpdateEvFn is NULL)
    WTSDK_ExportedCommand *     pExportedCommands;
    int                         iNumberOfCommands;

    // optional function used for UI update notifications (or NULL)
    WTSDK_UIUpdateEvFn *        pUIUpdateEvFn;
};




#endif // __WTSDKDEFS_PRIV_H

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


Written By
Experion
Canada Canada
You may know Oz from his WndTabs days. Oz has long since left client side development to work on web technologies and to consult in the R&D management field.

Comments and Discussions