[EMAIL PROTECTED] wrote:
Author: younes
Date: Sun Jul 15 22:56:19 2007
New Revision: 19084

URL: http://www.lyx.org/trac/changeset/19084
Log:
Add focus to current Work area by default.

 void GuiView::setCurrentWorkArea(WorkArea * work_area)
 {
        BOOST_ASSERT(work_area);
-       d.tab_widget_->setCurrentWidget(static_cast<GuiWorkArea *>(work_area));
+       GuiWorkArea * wa = static_cast<GuiWorkArea *>(work_area);
+       d.tab_widget_->setCurrentWidget(wa);
+       wa->setFocus();
 }

dynamic_cast<> and you should check that wa isn't null.

Angus

Reply via email to