Quantcast
Channel: Adobe Community : Popular Discussions - InDesign SDK
Viewing all articles
Browse latest Browse all 78596

multiple panels in a single .fr

$
0
0

hai all!

is it possible!?

 

 

this is my  .fr:

 

 

 

//==================================================================== ====================

// 

//  $File: $

// 

//  Owner: Ame

// 

//  $Author: $

// 

//  $DateTime: $

// 

//  $Revision: $

// 

//  $Change: $

// 

//  Copyright 1997-2008 Adobe Systems Incorporated. All rights reserved.

// 

//  NOTICE:  Adobe permits you to use, modify, and distribute this file in accordance

//  with the terms of the Adobe license agreement accompanying it.  If you have received

//  this file from a source other than Adobe, then your use, modification, or

//  distribution of it requires the prior written permission of Adobe.

// 

//==================================================================== ====================

 

#include "VCPlugInHeaders.h"

 

// General includes:

#include "MenuDef.fh"

#include "ActionDef.fh"

#include "ActionDefs.h"

#include "AdobeMenuPositions.h"

#include "LocaleIndex.h"

#include "PMLocaleIds.h"

#include "StringTable.fh"

#include "ObjectModelTypes.fh"

#include "ShuksanID.h"

#include "ActionID.h"

#include "CommandID.h"

#include "WorkspaceID.h"

#include "WidgetID.h"

#include "BuildNumber.h"

#include "PlugInModel_UIAttributes.h"

#include "PanelList.fh"

 

#include "InterfaceColorDefines.h"

#include "IControlViewDefs.h"

#include "SysControlIDs.h"

#include "Widgets.fh"// for PalettePanelWidget or DialogBoss

 

 

// Project includes:

#include "pplID.h"

#include "GenericID.h"

#include "ShuksanID.h"

#include "TextID.h"

 

#include "IDList.fh"

#include "IDListPair.fh"

 

#ifdef __ODFRC__

 

/*  Plugin version definition.

*/

resource PluginVersion (kSDKDefPluginVersionResourceID)

{

kTargetVersion,

kpplPluginID,

kSDKDefPlugInMajorVersionNumber, kSDKDefPlugInMinorVersionNumber,

kSDKDefHostMajorVersionNumber, kSDKDefHostMinorVersionNumber,

kpplCurrentMajorFormatNumber, kpplCurrentMinorFormatNumber,

{ kInDesignProduct},

{ kWildFS },

kUIPlugIn,

kpplVersion

};

 

/*  The ExtraPluginInfo resource adds extra information to the Missing Plug-in dialog

that is popped when a document containing this plug-in's data is opened when

this plug-in is not present. These strings are not translatable strings

since they must be available when the plug-in isn't around. They get stored

in any document that this plug-in contributes data to.

*/

resource ExtraPluginInfo(1)

{

kpplCompanyValue,// Company name

kpplMissingPluginURLValue,// URL

kpplMissingPluginAlertValue,// Missing plug-in alert text

};

 

 

 

 

/* Boss class definition.

*/

resource ClassDescriptionTable(kSDKDefClassDescriptionTableResourceID)

{{{

 

/**

This boss class supports two interfaces:

IActionComponent and IPMPersist.

 

 

@ingroup palco plugin

*/

Class

{

kpplActionComponentBoss,

kInvalidClass,

{

/** Handle the actions from the menu. */

IID_IACTIONCOMPONENT, kpplActionComponentImpl,

/** Persist the state of the menu across application instantiation.

Implementation provided by the API.*/

IID_IPMPERSIST, kPMPersistImpl

}

},

 

/**

This boss class inherits from an API panel boss class, and

adds an interface to control a pop-up menu on the panel.

The implementation for this interface is provided by the API.

 

 

@ingroup palco plugin

*/

 

Class

{

kpplPanelWidgetBoss,

kPalettePanelWidgetBoss,

{

/** The plug-in's implementation of ITextControlData with an exotic IID of IID_IPANELMENUDATA.

Implementation provided by the API.

*/

IID_IPANELMENUDATA, kCPanelMenuDataImpl,

}

},

 

 

 

 

 

 

 

//pannello delle preferenze

Class

{

kpplUIDialogBoss,

kPrimaryResourcePanelWidgetBoss,

{

 

IID_IDIALOGCONTROLLER, kpplUIDialogControllerImpl,

IID_IXDOCBKUIWIDGETOBSERVER, kpplUIDialogObserverImpl,

IID_IK2SERVICEPROVIDER, kDialogPanelServiceImpl,

IID_IPANELCREATOR, kpplUIPanelCreatorImpl,

 

 

 

 

 

}

},

 

 

 

}}};

 

/*  Implementation definition.

*/

resource FactoryList (kSDKDefFactoryListResourceID)

{

kImplementationIDSpace,

{

#include "pplFactoryList.h"

}

};

 

 

 

 

 

 

resource IDList (kSDKDefIDListPairResourceID)

{

{

// Impl ID for Preferences Selectable Dialog

kGlobalPrefsDialogServiceImpl,

},

};

 

 

resource IDListPair (kSDKDefIDListPairResourceID)

{

{

kGlobalPrefsDialogServiceImpl,// ID of Target Selectable Dialog (InDesign's)

pippo,// ID of Panel Resource to be added (Mine)

kpplPluginID// Plug-in ID that "owns" the Panel Resource to be added

},

};

 

 

 

 

 

 

/*  Menu definition.

*/

 

resource MenuDef (kSDKDefMenuResourceID)

{

{

// The About Plug-ins sub-menu item for this plug-in.

kpplAboutActionID,// ActionID (kInvalidActionID for positional entries)

kpplAboutMenuPath,// Menu Path.

kSDKDefAlphabeticPosition,// Menu Position.

kSDKDefIsNotDynamicMenuFlag,// kSDKDefIsNotDynamicMenuFlag or kSDKDefIsDynamicMenuFlag

 

 

// Separator for the popup menu on the panel

kpplSeparator1ActionID,

kpplInternalPopupMenuNameKey kSDKDefDelimiterAndSeparatorPath,// :- to mark an item as a separator.

kpplSeparator1MenuItemPosition,

kSDKDefIsNotDynamicMenuFlag,

 

// About this plugin submenu for the popup menu on the panel

kpplPopupAboutThisActionID,

kpplTargetMenuPath

kpplAboutThisMenuItemPosition,

kSDKDefIsNotDynamicMenuFlag,

 

 

kpplMnuPrefActionID,// ActionID

        "Main:AppleMenu:Preferences",// Menu Path.

        kSDKDefAlphabeticPosition, // Menu Position.

        kSDKDefIsNotDynamicMenuFlag,

 

}

};

 

 

resource ActionDef (kSDKDefActionResourceID)

{

{

kpplActionComponentBoss, // ClassID of boss class that implements the ActionID.

kpplAboutActionID,// ActionID.

kpplAboutMenuKey,// Sub-menu string.

kOtherActionArea,// Area name (see ActionDefs.h).

kNormalAction,// Type of action (see ActionDefs.h).

kDisableIfLowMem,// Enabling type (see ActionDefs.h).

kInvalidInterfaceID,// Selection InterfaceID this action cares about or kInvalidInterfaceID.

kSDKDefInvisibleInKBSCEditorFlag, // kSDKDefVisibleInKBSCEditorFlag or kSDKDefInvisibleInKBSCEditorFlag.

 

 

kpplActionComponentBoss,

kpplPopupAboutThisActionID,

kSDKDefAboutThisPlugInMenuKey,// Key to the name of this action

kOtherActionArea,

kNormalAction,

kDisableIfLowMem,

kInvalidInterfaceID,

kSDKDefInvisibleInKBSCEditorFlag,

 

 

 

 

        kpplActionComponentBoss,

        kpplMnuPrefActionID,// ActionID.

        "Palco...",// Sub-menu string.

        kEditMenuPreferencesActionArea,// Area name (see ActionDefs.h).

        kNormalAction,// Type of action (see ActionDefs.h).

        kDisableIfLowMem,// Enabling type (see ActionDefs.h).

        kInvalidInterfaceID,// Selection InterfaceID

        kSDKDefInvisibleInKBSCEditorFlag,

 

}

};

 

 

 

resource LocaleIndex ( kSDKDefStringsResourceID)

{

kStringTableRsrcType,

{

kWildFS, k_enUS, kSDKDefStringsResourceID + index_enUS

kWildFS, k_enGB, kSDKDefStringsResourceID + index_enUS

kWildFS, k_deDE, kSDKDefStringsResourceID + index_enUS

kWildFS, k_frFR, kSDKDefStringsResourceID + index_enUS

kWildFS, k_esES, kSDKDefStringsResourceID + index_enUS

kWildFS, k_ptBR, kSDKDefStringsResourceID + index_enUS

kWildFS, k_svSE, kSDKDefStringsResourceID + index_enUS

kWildFS, k_daDK, kSDKDefStringsResourceID + index_enUS

kWildFS, k_nlNL, kSDKDefStringsResourceID + index_enUS

kWildFS, k_itIT, kSDKDefStringsResourceID + index_enUS

kWildFS, k_nbNO, kSDKDefStringsResourceID + index_enUS

kWildFS, k_fiFI, kSDKDefStringsResourceID + index_enUS

kInDesignJapaneseFS, k_jaJP, kSDKDefStringsResourceID + index_jaJP

}

};

 

 

 

resource LocaleIndex (kSDKDefStringsNoTransResourceID)

{

kStringTableRsrcType,

{

kWildFS, k_Wild, kSDKDefStringsNoTransResourceID + index_enUS

}

};

 

resource StringTable (kSDKDefStringsNoTransResourceID + index_enUS)

{

k_enUS,// Locale Id

kEuropeanMacToWinEncodingConverter,// Character encoding converter

{

// No-Translate strings go here:

 

kpplInternalPopupMenuNameKey,kpplInternalPopupMenuNameKey,// No need to translate, internal menu name.

 

}

};

 

 

/*

 

resource LocaleIndex (pippo)

{

kViewRsrcType,

{

kWildFS, k_Wild, pippo + index_enUS

}

};

 

*/

 

resource LocaleIndex (kSDKDefPanelResourceID)

{

kViewRsrcType,

{

kWildFS, k_Wild, kSDKDefPanelResourceID + index_enUS

}

};

 

 

 

 

 

/*  Type definition.

*/

type pplPanelWidget(kViewRsrcType) : PalettePanelWidget(ClassID = kpplPanelWidgetBoss)

{

CPanelMenuData;

};

 

type pplUIPanelWidget (kViewRsrcType) : PrimaryResourcePanelWidget (ClassID = kpplUIDialogBoss) { };

 

 

resource PanelList (kSDKDefPanelResourceID)

{

{

// 1st panel in the list

kSDKDefPanelResourceID,// Resource ID for this panel (use SDK default rsrc ID)

kpplPluginID,// ID of plug-in that owns this panel

kIsResizable,

kpplPanelWidgetActionID,// Action ID to show/hide the panel

kpplPanelTitleKey,// Shows up in the Window list.

"",// Alternate menu path of the form "Main:Foo" if you want your palette menu item in a second place

0.0,// Alternate Menu position Alternate Menu position for determining menu order

0,0,// Rsrc ID, Plugin ID for a PNG icon resource to use for this palette

c_Panel

}

};

 

 

 

 

 

 

 

resource PanelList (pippo)

{

{

// 2st panel in the list

pippo,// Resource ID for this panel (use SDK default rsrc ID)

kpplPluginID,// ID of plug-in that owns this panel

kIsResizable,

kpplPanelWidgetActionID,// Action ID to show/hide the panel

kpplPanelTitleKey,// Shows up in the Window list.

"",// Alternate menu path of the form "Main:Foo" if you want your palette menu item in a second place

0.0,// Alternate Menu position Alternate Menu position for determining menu order

0,0,// Rsrc ID, Plugin ID for a PNG icon resource to use for this palette

c_Panel

}

};

 

 

 

 

resource pplPanelWidget(kSDKDefPanelResourceID + index_enUS)

{

__FILE__, __LINE__,// Localization macro

kpplPanelWidgetID,// WidgetID

kPMRsrcID_None,// RsrcID

kBindNone,// Binding (0=none)

0, 0, 207, 32,// Frame: left, top, right, bottom.

kTrue, kTrue,// Visible, Enabled

kFalse,// Erase background

kInterfacePaletteFill,// Erase to color

kFalse,// Draw dropshadow

kpplPanelTitleKey,// Panel name

{

StaticTextWidget

(

0,// WidgetId (default=0)

kSysStaticTextPMRsrcId,// RsrcId

kBindNone,// Frame binding

5, 10, 202, 27,// Frame: left, top, right, bottom.

kTrue, kTrue,// Visible, Enabled

kAlignLeft, kEllipsizeEnd, kTrue// Alignment, ellipsize style, convert ampersands

kpplStaticTextKey,// Initial text.

0// No associated widget

),

}

 

kpplInternalPopupMenuNameKey// Popup menu name (internal)

};

 

 

resource pplUIPanelWidget (pippo + index_enUS)

{

__FILE__, __LINE__,

kpplUIPanelWidgetID,// WidgetId

kPMRsrcID_None,// RsrcId

kBindNone,

// Frame: left, top, right, bottom

Frame(0,0,420,400),

kTrue,// Visible

kTrue,// Enabled

"super Palco",// Panel name

{

 

StaticTextWidget

(

0,// WidgetId (default=0)

kSysStaticTextPMRsrcId,// RsrcId

kBindNone,// Frame binding

5, 10, 202, 27,// Frame: left, top, right, bottom.

kTrue, kTrue,// Visible, Enabled

kAlignLeft, kEllipsizeEnd, kTrue// Alignment, ellipsize style, convert ampersands

"prova prova prova",// Initial text.

0// No associated widget

),

 

}

 

 

};

 

#endif // __ODFRC__

 

#include "ppl_enUS.fr"

#include "ppl_jaJP.fr"

 

 

 

 

I want put one of this 2 panels in to the global

 

preferences dialog... and one is the normal panel of UI plugin where is my problem?

 

any suggestion?

thanks!


Viewing all articles
Browse latest Browse all 78596

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>