Hello,
I am trying to create a nonlinear workflow. In essence, the first step has 2
buttons and when the user clicks on one of them, he goes through "wf1", if he
clicks onto the other one, he goes through "wf2". In each workflow step, I want
to load a different custom working area. I already succeed to load and display
a custom working area.
1. I would like to show only the tabs for the steps the user has already seen
and the current one in the tab bar.
2. I want that the user can only go back one step at a time, destroying the
current step.
3. I want to programatically get the user to the next step when he clicks on
some button.
I have the feeling that it is easiest by creating a new step programatically
when the user clicks on some button and then switch to it. Unfortunately, I
don't seem to be doing it right:
Core::Workflow::Pointer pWorkflow =
Core::Runtime::Kernel::GetWorkflowManager()->GetActiveWorkflow();
Core::WorkflowStep::Pointer pNextStep = Core::WorkflowStep::New("Next
Step!");
pWorkflow->AddStep(pNextStep);
Core::Runtime::Kernel::GetGraphicalInterface()->GetMainWindow()->UpdateActiveWorkflowLayout();
does not seem to add tabs. Funny thing is that the tabs appear the next time I
open gimias. This raises one more point: when restarting gimias, the user
should only see the first tab (i.e. the workflow should not be saved). So, how
do I add steps dynamically? Is that even supported? Or do you have any better
idea?
As to switching to the next tab programatically, I came up with this, taken
from coreWorkflowNavigationWidget.cxx, which seems to work: (mainly including
it in this email for others which might search for it):
wxWindow* mainWindow =
Core::Runtime::Kernel::GetGraphicalInterface()->GetMainWindow();
wxAuiNotebook* tabContainer =
wxDynamicCast(mainWindow->FindWindow(wxID_TabContainer), wxAuiNotebook);
wxWindowUpdateLocker noUpdates(tabContainer);
if(tabContainer) {
tabContainer->AdvanceSelection();
}
Best regards,
Lucas
------------------------------------------------------------------------------
BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts.
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
_______________________________________________
Gimias-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gimias-developers