예제 #1
0
void RHTMLbuttonmenu::AddTab(const char *name,const char *text,const char *alt)
{
 tbdb++;
 tb = (RHTMLmenubutton**) realloc(tb,sizeof(RHTMLmenubutton)*tbdb);
 tb[tbdb-1] = new RHTMLmenubutton(BRect(fx+2,0,fx+100,felsoview->Bounds().bottom),name,text,alt,tbdb-1,this);
 felsoview->AddChild(tb[tbdb-1]);
 fx=fx+tb[tbdb-1]->Bounds().right+2;
 AddMenuBar(name);
}
예제 #2
0
GUIFrame::GUIFrame( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : wxFrame( parent, id, title, pos, size, style )
{
    this->SetSizeHints( wxDefaultSize, wxDefaultSize );

    AddMenuBar();

    wxBoxSizer* bSizer0;
    bSizer0 = new wxBoxSizer( wxVERTICAL );
    m_notebook1 = new wxNotebook( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );

    m_commonExpandFlags = wxSizerFlags(1).Expand().Border(wxALL, 20);

    //Add panels into m_notebook1

    //Tiny Controls
    AddPanel_1();
    //Multiple choice Controls
    AddPanel_2();
    //[Rich]Text Controls
    AddPanel_3();
    //Picker Controls
    AddPanel_4();
    //Drop-down Controls
    AddPanel_5();

    m_notebook1->ChangeSelection(0);

    bSizer0->Add( m_notebook1, 1, wxEXPAND | wxALL, 0 );

    this->SetSizer( bSizer0 );
    this->Layout();
    bSizer0->Fit( this );
    statusBar = this->CreateStatusBar( 1, wxST_SIZEGRIP, wxID_ANY );

    // Connect Events
    this->Connect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( GUIFrame::OnClose ) );
}
예제 #3
0
CAssemblyWindow::CAssemblyWindow(
	BRect frame,
	CMeVDoc *document,
	bool hasSettings)
	:	CTrackWindow(frame, document, true, 
					 (CEventTrack *)document->FindTrack(1),
					 hasSettings)
{
	D_ALLOC(("CAssemblyWindow::CAssemblyWindow(%s)\n",
			 hasSettings ? "hasSettings == true" : "hasSettings == false"));

	document->FindTrack((int32)0)->AddObserver(this);

	AddMenuBar();
	AddToolBar();

	// ++++++ retrieve this from window settings if possible
	m_toolStates[0] = CEventEditor::TOOL_SELECT;

	// add the default strips
	BRect rect(Bounds());
	rect.top = ToolBar()->Frame().bottom + 1.0;
	rect.bottom -= B_H_SCROLL_BAR_HEIGHT;

	AddFrameView(rect, (CTrack *)Document()->FindTrack(1));
	stripFrame->AddType("Arrangement",
						ResourceUtils::LoadImage("AssemblyStrip"));

	if (!hasSettings)
	{
		// add default strip
		AddStrip("Arrangement", 1.0);
		stripFrame->PackStrips();
	}

	SetNewEventType(EvtType_Sequence);
}