+ if (style & wxHF_CONTENTS)
+ {
+ wxWindow *dummy = new wxPanel(m_NavigPan, wxID_HTML_INDEXPAGE);
+
+ if (style & wxHF_BOOKMARKS)
+ {
+ wxLayoutConstraints *b1 = new wxLayoutConstraints;
+ wxBitmapButton *bmpbt = new wxBitmapButton(dummy, wxID_HTML_BOOKMARKSREMOVE, wxBITMAP(wbkdel), wxDefaultPosition, wxSize(20,20));
+
+ b1->top.SameAs (dummy, wxTop, 10);
+ b1->right.SameAs (dummy, wxRight, 10);
+ b1->height.AsIs();
+ b1->width.AsIs();
+ bmpbt->SetConstraints(b1);
+
+ wxLayoutConstraints *b2 = new wxLayoutConstraints;
+ wxBitmapButton *bmpbt2 = new wxBitmapButton(dummy, wxID_HTML_BOOKMARKSADD, wxBITMAP(wbkadd), wxDefaultPosition, wxSize(20,20));
+
+ b2->top.SameAs (dummy, wxTop, 10);
+ b2->right.LeftOf (bmpbt, 2);
+ b2->height.AsIs();
+ b2->width.AsIs();
+ bmpbt2->SetConstraints(b2);
+
+#if wxUSE_TOOLTIPS
+ bmpbt->SetToolTip(_("Remove current page from bookmarks"));
+ bmpbt2->SetToolTip(_("Add current page to bookmarks"));
+#endif //wxUSE_TOOLTIPS
+
+ wxLayoutConstraints *b3 = new wxLayoutConstraints;
+ m_Bookmarks = new wxComboBox(dummy, wxID_HTML_BOOKMARKSLIST, wxEmptyString,
+ wxDefaultPosition, wxDefaultSize, 0, NULL, wxCB_READONLY | wxCB_SORT);
+ m_Bookmarks->Append(_("(bookmarks)"));
+ for (unsigned i = 0; i < m_BookmarksNames.GetCount(); i++)
+ m_Bookmarks->Append(m_BookmarksNames[i]);
+ m_Bookmarks->SetSelection(0);
+
+ b3->centreY.SameAs (bmpbt2, wxCentreY);
+ b3->left.SameAs (dummy, wxLeft, 10);
+ b3->right.LeftOf (bmpbt2, 5);
+ b3->height.AsIs();
+ m_Bookmarks->SetConstraints(b3);
+
+
+ wxLayoutConstraints *b4 = new wxLayoutConstraints;
+ m_ContentsBox = new wxTreeCtrl(dummy, wxID_HTML_TREECTRL,
+ wxDefaultPosition, wxDefaultSize,
+#ifdef __WXMAC__
+ wxSUNKEN_BORDER|wxTR_MAC_BUTTONS|wxTR_NO_LINES|wxTR_ROW_LINES );
+#else
+ wxSUNKEN_BORDER|wxTR_HAS_BUTTONS );
+#endif
+ m_ContentsBox->AssignImageList(ContentsImageList);
+
+ b4->top.Below (m_Bookmarks, 10);
+ b4->left.SameAs (dummy, wxLeft, 0);
+ b4->right.SameAs (dummy, wxRight, 0);
+ b4->bottom.SameAs (dummy, wxBottom, 0);
+ m_ContentsBox->SetConstraints(b4);
+
+ dummy->SetAutoLayout(TRUE);
+ dummy->Layout();
+
+ m_NavigPan->AddPage(dummy, _("Contents"));
+ }
+
+ else
+ {
+ m_ContentsBox = new wxTreeCtrl(m_NavigPan, wxID_HTML_TREECTRL,
+ wxDefaultPosition, wxDefaultSize,
+ wxTR_HAS_BUTTONS | wxSUNKEN_BORDER);
+ m_ContentsBox->AssignImageList(ContentsImageList);
+ m_NavigPan->AddPage(m_ContentsBox, _("Contents"));
+ }
+