本文整理汇总了C++中ReleaseISpinner函数的典型用法代码示例。如果您正苦于以下问题:C++ ReleaseISpinner函数的具体用法?C++ ReleaseISpinner怎么用?C++ ReleaseISpinner使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了ReleaseISpinner函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: GetDC
StraussShaderDlg::~StraussShaderDlg()
{
HDC hdc = GetDC(hRollup);
GetGPort()->RestorePalette(hdc, hOldPal);
ReleaseDC(hRollup, hdc);
if( pShader ) pShader->SetParamDlg(NULL,0);
for (long i=0; i < NMBUTS; i++ ){
ReleaseICustButton( texMBut[i] );
texMBut[i] = NULL;
}
for (long i=0; i<STRAUSS_NCOLBOX; i++)
if (cs[i]) ReleaseIColorSwatch(cs[i]); // mjm - 5.10.99
ReleaseISpinner(glSpin);
ReleaseISpinner(mtSpin);
ReleaseISpinner(trSpin);
DLSetWindowLongPtr(hRollup, NULL);
DLSetWindowLongPtr(hwHilite, NULL);
if(pShader){
IRollupWindow* pRollup = pMtlPar->GetMtlEditorRollup();
pShader->SetPanelOpen(pRollup->IsPanelOpen(pRollup->GetPanelIndex(hRollup)));
}
hwHilite = hRollup = NULL;
}
示例2: GetDC
WardShaderDlg::~WardShaderDlg()
{
HDC hdc = GetDC(hRollup);
GetGPort()->RestorePalette(hdc, hOldPal);
ReleaseDC(hRollup, hdc);
if( pShader ) pShader->SetParamDlg(NULL,0);
for (long i=0; i < NMBUTS; i++ ){
ReleaseICustButton( texMBut[i] );
texMBut[i] = NULL;
}
for (i=0; i<WARD_NCOLBOX; i++)
if (cs[i]) ReleaseIColorSwatch(cs[i]); // mjm - 5.10.99
ReleaseISpinner(slevSpin);
ReleaseISpinner(dlevSpin);
ReleaseISpinner(glxSpin);
ReleaseISpinner(glySpin);
ReleaseISpinner(trSpin);
SetWindowLongPtr(hRollup, GWLP_USERDATA, NULL);
SetWindowLongPtr(hwHilite, GWLP_USERDATA, NULL);
hwHilite = hRollup = NULL;
}
示例3: NumMapsDlgProc
static INT_PTR CALLBACK NumMapsDlgProc(
HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam)
{
switch (msg) {
case WM_INITDIALOG: {
ISpinnerControl *spin =
SetupIntSpinner(
hWnd,IDC_COMP_NUMMAPSSPIN,IDC_COMP_NUMMAPS,
2,1000,(int)lParam);
ReleaseISpinner(spin);
CenterWindow(hWnd,GetParent(hWnd));
break;
}
case WM_COMMAND:
switch (LOWORD(wParam)) {
case IDOK: {
ISpinnerControl *spin =
GetISpinner(GetDlgItem(hWnd,IDC_COMP_NUMMAPSSPIN));
EndDialog(hWnd,spin->GetIVal());
ReleaseISpinner(spin);
break;
}
case IDCANCEL:
EndDialog(hWnd,-1);
break;
}
break;
default:
return FALSE;
}
return TRUE;
}
示例4: EnableWindow
void TestSplitByAmountDlgProc::UpdateTypeDlg( HWND hWnd, int type )
{
bool enable = (type == kSplitByAmount_testType_fraction);
bool bRandom = enable;
EnableWindow( GetDlgItem( hWnd, IDC_RATIOTEXT ), enable );
ISpinnerControl* spin = GetISpinner( GetDlgItem( hWnd, IDC_RATIO2SPIN ) );
spin->Enable( enable );
ReleaseISpinner( spin );
enable = (type == kSplitByAmount_testType_everyN);
EnableWindow( GetDlgItem( hWnd, IDC_EVERYNTEXT ), enable );
spin = GetISpinner( GetDlgItem( hWnd, IDC_EVERYNSPIN ) );
spin->Enable( enable );
ReleaseISpinner( spin );
enable = (type >= kSplitByAmount_testType_firstN);
EnableWindow( GetDlgItem( hWnd, IDC_FIRSTNTEXT ), enable );
EnableWindow( GetDlgItem( hWnd, IDC_PERSOURCE ), enable );
spin = GetISpinner( GetDlgItem( hWnd, IDC_FIRSTNSPIN ) );
spin->Enable( enable );
ReleaseISpinner( spin );
EnableWindow( GetDlgItem( hWnd, IDC_UNIQUENESSBOX ), bRandom );
EnableWindow( GetDlgItem( hWnd, IDC_SEEDTEXT ), bRandom );
spin = GetISpinner( GetDlgItem( hWnd, IDC_SEEDSPIN ) );
spin->Enable( bRandom );
ReleaseISpinner( spin );
ICustButton* button = GetICustButton( GetDlgItem( hWnd, IDC_NEW ) );
button->Enable( bRandom );
ReleaseICustButton( button );
}
示例5: ExportDlgProc
// Dialog proc
static INT_PTR CALLBACK ExportDlgProc(HWND hWnd, UINT msg,
WPARAM wParam, LPARAM lParam)
{
Interval animRange;
ISpinnerControl *spin;
AscOut *exp = (AscOut*)GetWindowLongPtr(hWnd,GWLP_USERDATA);
switch (msg) {
case WM_INITDIALOG:
exp = (AscOut*)lParam;
SetWindowLongPtr(hWnd,GWLP_USERDATA,lParam);
CenterWindow(hWnd, GetParent(hWnd));
// Setup the spinner controls for the floating point precision
spin = GetISpinner(GetDlgItem(hWnd, IDC_PREC_SPIN));
spin->LinkToEdit(GetDlgItem(hWnd,IDC_PREC), EDITTYPE_INT );
spin->SetLimits(1, 10, TRUE);
spin->SetScale(1.0f);
spin->SetValue(exp->GetPrecision() ,FALSE);
ReleaseISpinner(spin);
// Setup the spinner control for the static frame#
// We take the frame 0 as the default value
animRange = exp->GetInterface()->GetAnimRange();
spin = GetISpinner(GetDlgItem(hWnd, IDC_STATIC_FRAME_SPIN));
spin->LinkToEdit(GetDlgItem(hWnd,IDC_STATIC_FRAME), EDITTYPE_INT );
spin->SetLimits(animRange.Start() / GetTicksPerFrame(), animRange.End() / GetTicksPerFrame(), TRUE);
spin->SetScale(1.0f);
spin->SetValue(0, FALSE);
ReleaseISpinner(spin);
break;
case CC_SPINNER_CHANGE:
spin = (ISpinnerControl*)lParam;
break;
case WM_COMMAND:
switch (LOWORD(wParam)) {
case IDOK:
spin = GetISpinner(GetDlgItem(hWnd, IDC_PREC_SPIN));
exp->SetPrecision(spin->GetIVal());
ReleaseISpinner(spin);
spin = GetISpinner(GetDlgItem(hWnd, IDC_STATIC_FRAME_SPIN));
exp->SetStaticFrame(spin->GetIVal() * GetTicksPerFrame());
ReleaseISpinner(spin);
EndDialog(hWnd, 1);
break;
case IDCANCEL:
EndDialog(hWnd, 0);
break;
}
break;
default:
return FALSE;
}
return TRUE;
}
示例6: ReleaseICustEdit
void ConvexApproximationObject::DestroyUI(HWND hWnd)
{
ReleaseICustEdit (m_maxConcavity);
ReleaseISpinner (m_maxConcavitySpinner);
ReleaseICustEdit (m_maxSegments);
ReleaseISpinner (m_maxSegmentsSpinner);
}
示例7: ReleaseISpinner
void RandKeysUtil::Destroy()
{
ReleaseISpinner(iPosTime);
ReleaseISpinner(iNegTime);
ReleaseISpinner(iPosVal);
ReleaseISpinner(iNegVal);
if (iu) iu->TVUtilClosing(this);
}
示例8: GetISpinner
void TestSpawnOnCollisionDlgProc::UpdateSpeedTypeDlg( HWND hWnd, int speedType )
{
ISpinnerControl* spin = GetISpinner( GetDlgItem( hWnd, IDC_SPEEDSPIN ) );
spin->Enable(speedType == kSpawnCollision_speedType_units);
ReleaseISpinner(spin);
spin = GetISpinner( GetDlgItem( hWnd, IDC_INHERITEDSPIN ) );
spin->Enable(speedType == kSpawnCollision_speedType_inherited);
ReleaseISpinner(spin);
}
示例9: EnableWindow
void PFOperatorInstanceShapeDlgProc::UpdateScaleDlg( HWND hWnd, BOOL setScale)
{
ISpinnerControl *spin;
bool enable = (setScale != 0);
EnableWindow( GetDlgItem( hWnd, IDC_VARIATIONTEXT ), enable );
spin = GetISpinner( GetDlgItem( hWnd, IDC_PARTICLESCALESPIN ) );
spin->Enable( enable );
ReleaseISpinner( spin );
spin = GetISpinner( GetDlgItem( hWnd, IDC_VARIATIONSPIN ) );
spin->Enable( enable );
ReleaseISpinner( spin );
}
示例10: GetISpinner
Value*
FooControl::set_property(Value** arg_list, int count)
{
Value* val = arg_list[0];
Value* prop = arg_list[1];
if (prop == n_value)
{
value = val->to_float();
if (parent_rollout != NULL && parent_rollout->page != NULL)
{
ISpinnerControl* spin = GetISpinner(GetDlgItem(parent_rollout->page, control_ID));
if (spin_type == EDITTYPE_INT)
spin->SetValue((int)value, FALSE);
else
spin->SetValue(value, FALSE);
ReleaseISpinner(spin);
}
}
else if (prop == n_range)
{
Point3 p;
if (is_point3(val))
p = val->to_point3();
else
throw TypeError (MaxSDK::GetResourceStringAsMSTR(IDS_SPINNER_RANGE_MUST_BE_A_VECTOR), val);
min = p.x; max = p.y; value = p.z;
if (parent_rollout != NULL && parent_rollout->page != NULL)
{
ISpinnerControl* spin = GetISpinner(GetDlgItem(parent_rollout->page, control_ID));
if (spin_type == EDITTYPE_INT)
{
spin->SetLimits((int)p.x, (int)p.y, FALSE);
spin->SetScale(1.0F);
spin->SetValue((int)p.z, FALSE);
}
else
{
spin->SetLimits(p.x, p.y, FALSE);
spin->SetScale(0.1F);
spin->SetValue(p.z, FALSE);
}
ReleaseISpinner(spin);
}
}
else
return RolloutControl::set_property(arg_list, count);
return val;
}
示例11: ReleaseISpinner
FloatLimitControlDlg::~FloatLimitControlDlg()
{
ReleaseISpinner(mUpperLimitSpin);
ReleaseISpinner(mLowerLimitSpin);
ReleaseISpinner(mUpperWidthSpin);
ReleaseISpinner(mLowerWidthSpin);
LimitControlDlgManager::GetLimitCtrlDlgManager()->RemoveDialog(this);
theHold.Suspend();
DeleteAllRefsFromMe();
theHold.Resume();
GetCOREInterface()->UnRegisterTimeChangeCallback(this);
}
示例12: GetISpinner
void RendSplineParamsMapDlgProc::Initialize(HWND hWnd, TimeValue t)
{
if (hWnd == NULL) return;
else
{
ISpinnerControl *iSpin = GetISpinner(GetDlgItem(hWnd, IDC_ASPECTSPIN));
iSpin->LinkToEdit(GetDlgItem(hWnd, IDC_ASPECT), EDITTYPE_FLOAT);
iSpin->SetLimits(0.0f,99999999.0f);
iSpin->SetAutoScale(TRUE);
ReleaseISpinner(iSpin);
if (RendSpline::hLockButton == NULL) {
HBITMAP hBitmap, hMask;
RendSpline::hLockButton = ImageList_Create(16, 15, TRUE, 2, 0);
hBitmap = LoadBitmap(RendSplineDesc.HInstance(), MAKEINTRESOURCE(IDB_LOCK));
hMask = LoadBitmap(RendSplineDesc.HInstance(), MAKEINTRESOURCE(IDB_LOCKMASK));
ImageList_Add(RendSpline::hLockButton,hBitmap,hMask);
DeleteObject(hBitmap);
DeleteObject(hMask);
}
ICustButton *lockAspect = GetICustButton(GetDlgItem(hWnd,IDC_ASPECTLOCK));
lockAspect->SetImage(RendSpline::hLockButton,0,0,1,1,16,15);
lockAspect->SetType(CBT_CHECK);
ReleaseICustButton(lockAspect);
CheckRadioButton(hWnd, IDC_VIEWPORT, IDC_RENDERER, IDC_RENDERER);
BOOL usePhysUVs = mod->GetUsePhysicalScaleUVs();
CheckDlgButton(hWnd, IDC_REAL_WORLD_MAP_SIZE, usePhysUVs);
}
}
示例13: FixHeight
void FixHeight(IParamBlock *pblock,TimeValue t,HWND hWnd,BOOL increate)
{ float radius,height,r2,minh;
BOOL con,minush;
pblock->GetValue(PB_RADIUS,t,radius,FOREVER);
pblock->GetValue(PB_CENTERS,t,con,FOREVER);
pblock->GetValue(PB_HEIGHT,(increate?0:t),height,FOREVER);
r2=2.0f*radius;
minush=height<0.0f;
minh=((minush)?-r2:r2);
height=(float)fabs(height);
if (con) height+=r2;
if (hWnd)
{ ISpinnerControl *spin2 = GetISpinner(GetDlgItem(hWnd,IDC_SC_HEIGHTSPIN));
if (minush) spin2->SetLimits(MIN_HEIGHT,minh);
else spin2->SetLimits(minh,BMAX_HEIGHT,FALSE);
ReleaseISpinner(spin2);
}
//O.Z. *** begin fix for bug# 175299
if (height<r2)
pblock->SetValue(PB_HEIGHT,(increate?0:t),minh+DEF_HEIGHT);
else if ( (fabs(height)-fabs(2.0f * radius)) <= .001f)
pblock->SetValue(PB_HEIGHT,(increate?0:t),(height+DEF_HEIGHT));
//O.Z. *** end bug fix
}
示例14: TurnSpinner
void TurnSpinner(HWND hWnd,int SpinNum,BOOL ison)
{
ISpinnerControl *spin2 = GetISpinner(GetDlgItem(hWnd,SpinNum));
if (ison) spin2->Enable();else spin2->Disable();
ReleaseISpinner(spin2);
};
示例15: SetupMtlSubNameCombo
void MaterialUIHandler::ValidateUINameCombo (HWND hWnd, EPolyMod *pMod) {
SetupMtlSubNameCombo (hWnd, pMod);
ISpinnerControl* spin = NULL;
spin = GetISpinner(GetDlgItem(hWnd,IDC_MAT_IDSPIN));
if (spin) UpdateNameCombo (hWnd, spin);
ReleaseISpinner(spin);
}