~ubuntu-branches/ubuntu/maverick/wxwidgets2.8/maverick-proposed

« back to all changes in this revision

Viewing changes to src/html/helpwnd.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Devid Filoni
  • Date: 2008-06-30 22:02:17 UTC
  • mfrom: (1.1.5 upstream)
  • Revision ID: james.westby@ubuntu.com-20080630220217-vag3tkfp91t0453d
Tags: 2.8.8.0-0ubuntu1
* New upstream version, based on the upstream tarball
  wxPython-src-2.8.8.0.tar.bz2, remove upstream debian dir (LP: #244355).
* Add debian/watch file, LP: #242164.
* Edit get-orig-source target to provide a .orig.tar.gz with the same md5 for
  each .orig.tar.gz generated.
* debian/rules: remove get-orig-source from .PHONY target.
* debian/control.in: add python-wxtools in python-wxgtk=V=U Suggests field.
* Do not apply fix_from_upstream_svn_r52465 patch, not needed.
* Regenerate octave_oct, tcl_tk_tcl patches for the new version.
* Fix spelling-error-in-description lintian warning.
* Fix depends-on-obsolete-package lintian error.
* Fix executable-not-elf-or-script lintian warnings.
* Fix script-not-executable lintian warnings.
* Fix missing-dependency-on-libc lintian error.
* Fix dbg-package-missing-depends lintian warnings.
* Fix package-contains-empty-directory lintian warnings.
* Fix manpage-has-errors-from-man lintian warning.
* Fix image-file-in-usr-lib lintian warnings:
  - add editra_pixmaps patch
  - add xrced_bitmaps patch
* Fix unused-override lintian info.
* Fix malformed-override lintian errors.
* Fix extra-license-file lintian warnings.
* Install upstream wx.pth instead of generated file links (LP: #211553).
* Add editra.png, pyshell.png (encoded using uuencode) icons, LP: #236876:
  - debian/rules: use uudecode to decode .png icons.
* Add a new pyshell.xpm icon.
* Fix doc-base-file-references-missing-file lintian error.
* Fix doc-base-unknown-section lintian warning.
* Fix ruby-script-but-no-ruby-dep lintian errors.
* Fix wish-script-but-no-wish-dep lintian errors.
* Fix missing-dep-for-interpreter errors.
* Bump Standards-Version to 3.8.0.

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
// Notes:       Based on htmlhelp.cpp, implementing a monolithic
5
5
//              HTML Help controller class,  by Vaclav Slavik
6
6
// Author:      Harm van der Heijden and Vaclav Slavik
7
 
// RCS-ID:      $Id: helpwnd.cpp 48873 2007-09-21 13:30:23Z JS $
 
7
// RCS-ID:      $Id: helpwnd.cpp 54186 2008-06-13 12:52:43Z JS $
8
8
// Copyright:   (c) Harm van der Heijden and Vaclav Slavik
9
9
// Licence:     wxWindows licence
10
10
/////////////////////////////////////////////////////////////////////////////
315
315
{
316
316
    m_hfStyle = helpStyle;
317
317
 
318
 
    wxImageList *ContentsImageList = new wxImageList(16, 16);
319
 
    ContentsImageList->Add(wxArtProvider::GetIcon(wxART_HELP_BOOK,
320
 
                                                  wxART_HELP_BROWSER,
321
 
                                                  wxSize(16, 16)));
322
 
    ContentsImageList->Add(wxArtProvider::GetIcon(wxART_HELP_FOLDER,
323
 
                                                  wxART_HELP_BROWSER,
324
 
                                                  wxSize(16, 16)));
325
 
    ContentsImageList->Add(wxArtProvider::GetIcon(wxART_HELP_PAGE,
326
 
                                                  wxART_HELP_BROWSER,
327
 
                                                  wxSize(16, 16)));
328
 
 
329
318
    // Do the config in two steps. We read the HtmlWindow customization after we
330
319
    // create the window.
331
320
    if (m_Config)
365
354
#ifdef __WXMSW__
366
355
    wxBorder htmlWindowBorder = GetThemedBorderStyle();
367
356
    if (htmlWindowBorder == wxBORDER_SUNKEN)
368
 
        htmlWindowBorder = wxBORDER_SIMPLE;
 
357
        htmlWindowBorder = wxBORDER_SIMPLE;
369
358
#else
370
359
    wxBorder htmlWindowBorder = wxBORDER_SIMPLE;
371
360
#endif
459
448
#endif
460
449
                                       );
461
450
 
 
451
        wxImageList *ContentsImageList = new wxImageList(16, 16);
 
452
        ContentsImageList->Add(wxArtProvider::GetIcon(wxART_HELP_BOOK,
 
453
                                                      wxART_HELP_BROWSER,
 
454
                                                      wxSize(16, 16)));
 
455
        ContentsImageList->Add(wxArtProvider::GetIcon(wxART_HELP_FOLDER,
 
456
                                                      wxART_HELP_BROWSER,
 
457
                                                      wxSize(16, 16)));
 
458
        ContentsImageList->Add(wxArtProvider::GetIcon(wxART_HELP_PAGE,
 
459
                                                      wxART_HELP_BROWSER,
 
460
                                                      wxSize(16, 16)));
 
461
 
462
462
        m_ContentsBox->AssignImageList(ContentsImageList);
463
463
 
464
464
        topsizer->Add(m_ContentsBox, 1,
592
592
 
593
593
wxHtmlHelpWindow::~wxHtmlHelpWindow()
594
594
{
 
595
    if ( m_helpController )
 
596
        m_helpController->SetHelpWindow(NULL);
 
597
 
595
598
    delete m_mergedIndex;
596
599
 
597
600
    // PopEventHandler(); // wxhtmlhelpcontroller (not any more!)
1227
1230
 
1228
1231
        topsizer->Add(new wxStaticText(this, wxID_ANY, _("Preview:")),
1229
1232
                        0, wxLEFT | wxTOP, 10);
 
1233
 
 
1234
        int style = wxHW_SCROLLBAR_AUTO;
 
1235
 
 
1236
#ifdef __WXMSW__
 
1237
        style |= GetThemedBorderStyle();
 
1238
#else
 
1239
        style |= wxBORDER_SUNKEN;
 
1240
#endif
 
1241
        topsizer->AddSpacer(5);
 
1242
 
1230
1243
        topsizer->Add(TestWin = new wxHtmlWindow(this, wxID_ANY, wxDefaultPosition, wxSize(20, 150),
1231
 
                                                 wxHW_SCROLLBAR_AUTO | wxSUNKEN_BORDER),
1232
 
                        1, wxEXPAND | wxLEFT|wxTOP|wxRIGHT, 10);
 
1244
                                                 style),
 
1245
                        1, wxEXPAND | wxLEFT|wxRIGHT, 10);
1233
1246
 
1234
1247
        wxBoxSizer *sizer2 = new wxBoxSizer(wxHORIZONTAL);
1235
1248
        wxButton *ok;