Added cmDspUi2 two-dimensional drag UI control.
This commit is contained in:
parent
f8dc6ccd78
commit
2c1be3cf84
@ -23,6 +23,7 @@ extern "C" {
|
|||||||
kScoreDuiId, // ui<--eng create a score control
|
kScoreDuiId, // ui<--eng create a score control
|
||||||
kTakeSeqBldrDuiId, // ui<--eng create a take sequence builder
|
kTakeSeqBldrDuiId, // ui<--eng create a take sequence builder
|
||||||
kTakeSeqRendDuiId, // ui<--eng create a take sequence renderer
|
kTakeSeqRendDuiId, // ui<--eng create a take sequence renderer
|
||||||
|
kTwodDuiId, // ui<--eng create a 2d control
|
||||||
kNumberDuiId, // ui<--eng create a number box
|
kNumberDuiId, // ui<--eng create a number box
|
||||||
kTextDuiId, // ui<--eng create a text entry control
|
kTextDuiId, // ui<--eng create a text entry control
|
||||||
kFnameDuiId, // ui<--eng create a file/directory picker control
|
kFnameDuiId, // ui<--eng create a file/directory picker control
|
||||||
|
@ -405,6 +405,7 @@ extern "C" {
|
|||||||
cmDspRC_t cmDspUiScoreCreate( cmDspCtx_t* ctx, cmDspInst_t* inst, unsigned scFileVarId, unsigned selVarId, unsigned smpIdxVarId, unsigned pitchVarId, unsigned velVarId, unsigned locIdxVarIdx, unsigned evtIdxVarIdx, unsigned dynLvlVarIdx, unsigned valTypeVarIdx, unsigned valueVarIdx );
|
cmDspRC_t cmDspUiScoreCreate( cmDspCtx_t* ctx, cmDspInst_t* inst, unsigned scFileVarId, unsigned selVarId, unsigned smpIdxVarId, unsigned pitchVarId, unsigned velVarId, unsigned locIdxVarIdx, unsigned evtIdxVarIdx, unsigned dynLvlVarIdx, unsigned valTypeVarIdx, unsigned valueVarIdx );
|
||||||
cmDspRC_t cmDspUiTakeSeqBldrCreate( cmDspCtx_t* ctx, cmDspInst_t* inst, unsigned fileNameVarId, unsigned ptrVarId, unsigned selVarId, unsigned refreshVarId );
|
cmDspRC_t cmDspUiTakeSeqBldrCreate( cmDspCtx_t* ctx, cmDspInst_t* inst, unsigned fileNameVarId, unsigned ptrVarId, unsigned selVarId, unsigned refreshVarId );
|
||||||
cmDspRC_t cmDspUiTakeSeqRendCreate( cmDspCtx_t* ctx, cmDspInst_t* inst, unsigned ptrVarId, unsigned refreshVarId, unsigned selVarId );
|
cmDspRC_t cmDspUiTakeSeqRendCreate( cmDspCtx_t* ctx, cmDspInst_t* inst, unsigned ptrVarId, unsigned refreshVarId, unsigned selVarId );
|
||||||
|
cmDspRC_t cmDspUi2dCreate( cmDspCtx_t* ctx, cmDspInst_t* inst, unsigned xVarId, unsigned yVarId, unsigned radiusVarId, unsigned angleVarId);
|
||||||
|
|
||||||
cmDspRC_t cmDspUiNewColumn( cmDspCtx_t* ctx, unsigned colW );
|
cmDspRC_t cmDspUiNewColumn( cmDspCtx_t* ctx, unsigned colW );
|
||||||
cmDspRC_t cmDspUiInsertHorzBorder( cmDspCtx_t* ctx );
|
cmDspRC_t cmDspUiInsertHorzBorder( cmDspCtx_t* ctx );
|
||||||
|
@ -457,6 +457,27 @@ cmDspRC_t cmDspUiTakeSeqRendCreate( cmDspCtx_t* ctx, cmDspInst_t* inst, unsigne
|
|||||||
return rc;
|
return rc;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
cmDspRC_t cmDspUi2dCreate( cmDspCtx_t* ctx, cmDspInst_t* inst, unsigned xVarId, unsigned yVarId, unsigned radiusVarId, unsigned angleVarId)
|
||||||
|
{
|
||||||
|
cmDspRC_t rc;
|
||||||
|
unsigned arr[] = { xVarId, yVarId, radiusVarId, angleVarId };
|
||||||
|
cmDspValue_t v;
|
||||||
|
unsigned vn = sizeof(arr)/sizeof(arr[0]);
|
||||||
|
cmDsvSetUIntMtx(&v,arr,vn,1);
|
||||||
|
|
||||||
|
// tell the UI to create a sequence render control
|
||||||
|
if((rc = _cmDspUiMsg( ctx, kUiSelAsId, kTwodDuiId, 0, inst, cmInvalidId, &v )) != kOkDspRC )
|
||||||
|
return cmDspInstErr(ctx,inst,kUiEleCreateFailDspRC,"2-d UI element create failed.");
|
||||||
|
|
||||||
|
// Setting kUiDsvFl will cause variable values to be sent to the UI whenever they change.
|
||||||
|
cmDspInstVarSetFlags( ctx, inst, xVarId, kUiDsvFl );
|
||||||
|
cmDspInstVarSetFlags( ctx, inst, yVarId, kUiDsvFl );
|
||||||
|
cmDspInstVarSetFlags( ctx, inst, radiusVarId, kUiDsvFl );
|
||||||
|
cmDspInstVarSetFlags( ctx, inst, angleVarId, kUiDsvFl );
|
||||||
|
|
||||||
|
return rc;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
cmDspRC_t cmDspUiNewColumn( cmDspCtx_t* ctx, unsigned colW )
|
cmDspRC_t cmDspUiNewColumn( cmDspCtx_t* ctx, unsigned colW )
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user