Project

General

Profile

Merging two project

Added by Kim Forest almost 11 years ago

Hi folks !

I've started two distinct project on the Hello example application and i'm now at the step of joining these two part together and add an authentification for security purpose.

I've started by creating a navigation bar and ireally don't know how to add these to my menu button. these two project aren't only a display it interact with hardware and rely on Timer and external thread to function proprely.

So i can't modify these project as WWidget object.

To be more precise, i need that when i clic on the navigation bar on my first project name, i need to create this class and when i switch to my other project i need to destroy the last one (because i use serial port). ( i may not need to destroy the last one, but at least to create the class when i clic )

does someone are able to help thought this ?

thanks in advance

Kim


Replies (1)

RE: Merging two project - Added by Kim Forest almost 11 years ago

Hi there !

i've find the way to do this !

the Wt website use what i was searching about !

here how :

WServer server(argv[0]);

    server.setServerConfiguration(argc, argv, WTHTTP_CONFIGURATION);

//First Application
    server.addEntryPoint(Application,
             boost::bind(&createJWtHomeApplication, _1, blogDb),
             "/jwt", "/css/jwt/favicon.ico");
//second Application
    server.addEntryPoint(Application,
             boost::bind(&createWtHomeApplication, _1, blogDb),
             "", "/css/wt/favicon.ico");

    if (server.start()) {// Start the WtHttp server and stay in until we ask for shutdown
      WServer::waitForShutdown();
      server.stop();
    }
    (1-1/1)