Author Topic: Project Wizard - Couple of questions  (Read 10301 times)

Offline srini2174

  • Multiple posting newcomer
  • *
  • Posts: 13
Re: Project Wizard - Couple of questions
« Reply #15 on: October 28, 2006, 01:14:16 pm »
Hi,
    I am trying to write a wizard script for wxsmith. I have created a directory wxsmith under templates\wizard directory.  I just copied the wizard.script from wxwidgets into this newly created folder.  I added the line    RegisterWizard(wizProject,     _T("wxSmith"),      _T("wxSmith application"),   _T("GUI"));
in the config.script file.  When I try to open a new wxsmith project I still find only the old dialog.

    I just checked the sources and I found that wxsmithwizard.cpp contains the following code

CompileTargetBase* wxSmithWizard::Launch(int Index, wxString* pFilename)
{
    if ( !wxsPLUGIN() )
    {
        wxMessageBox(
            _("wxSmith plugin is not enable. Please enable it before running wizard"));
            return 0;
    }
    wxsWizard Dlg(0L);
    Dlg.ShowModal();
    return 0;
}

I think this calls wxswizard.  How do I make this call my script?   Thanks in advance for any help.  I feel the code should call the script by default and if this fails should set some flag and based on the value set for this flag it should then call wxswizard (which is used currently).   This would help someone to develop the script separately and plugin at any time in the future.

Regards,
Srinivasan.B

Offline mandrav

  • Project Leader
  • Administrator
  • Lives here!
  • *****
  • Posts: 4291
    • Code::Blocks IDE
Re: Project Wizard - Couple of questions
« Reply #16 on: October 28, 2006, 06:49:11 pm »
The script-based wizards are provided by another plugin (not wxSmith). Try "File->New->Project". Your wizard should show up.
Be patient!
This bug will be fixed soon...

Offline takeshi miya

  • Lives here!
  • ****
  • Posts: 1487
Re: Project Wizard - Couple of questions
« Reply #17 on: October 28, 2006, 07:00:05 pm »
srini2174, I don't think you could yet make a scriptedwizard for wxSmith, you would actually have to call project->AddSmithConfig(true); , add resources and so on, and I think you can't do all of that from the scripts, although I could be wrong.