Exemple #1
0
//------------------------------------------------------------------------------
// newSubpage() -- change subpages
//------------------------------------------------------------------------------
bool Page::newSubpage(Page* const np1, Page* theCaller, Basic::Object* theArg)
{
    bool ok = false;
    if (np1 != 0) {
        cpName.empty();	    // Unknown name
        np = np1;
        np->pageArg = theArg;
        np->caller  = theCaller;
        clearSubpageStack();
        ok = true;
    }
    return ok;
}
Exemple #2
0
//------------------------------------------------------------------------------
// newSubpage() -- change subpages by name; returns true of page was found
//------------------------------------------------------------------------------
bool Page::newSubpage(const char* const name, Page* theCaller, Basic::Object* theArg)
{
    bool ok = false;
    Basic::Pair* p = 0;
    if (subpages != 0) p = subpages->findByName(name);
    if (p != 0) {
        cpName = name;	// It's our page
        np = (Page*) p->object();
        np->pageArg = theArg;
        np->caller  = theCaller;
        clearSubpageStack();
        ok = true;
    }
    return ok;
}
Exemple #3
0
//------------------------------------------------------------------------------
// newSubpage() -- change subpages by name; returns true of page was found
//------------------------------------------------------------------------------
bool Page::newSubpage(const char* const name, Page* theCaller, base::Object* theArg)
{
    bool ok = false;
    base::Pair* p = nullptr;
    if (subpages != nullptr) p = subpages->findByName(name);
    if (p != nullptr) {
        cpName = name;            // It's our page
        np = static_cast<Page*>(p->object());
        np->pageArg = theArg;
        np->caller  = theCaller;
        clearSubpageStack();
        ok = true;
    }
    return ok;
}