]> git.lyx.org Git - lyx.git/blobdiff - src/BufferView.C
Applied Angus patch to compile on DEC C++ and to avoid name clashes
[lyx.git] / src / BufferView.C
index ef2fdf83dc2a1e26012d80f4e5d47942a47fb4b0..1e7db9e20b2b39d0dc69d57a2001c3ae1c6820ac 100644 (file)
@@ -46,13 +46,13 @@ Buffer * BufferView::buffer() const
 
 LyXScreen * BufferView::screen() const
 {
-       return pimpl_->screen_;
+       return pimpl_->screen_.get();
 }
 
 
 WorkArea * BufferView::workarea() const
 {
-       return pimpl_->workarea_;
+       return &pimpl_->workarea_;
 }
 
 
@@ -116,6 +116,12 @@ void BufferView::updateScrollbar()
 }
 
 
+void BufferView::scrollCB(double value)
+{
+       pimpl_->scrollCB(value);
+}
+
+
 Inset * BufferView::checkInsetHit(LyXText * text, int & x, int & y,
                                  unsigned int button)
 {
@@ -135,64 +141,6 @@ int BufferView::resizeCurrentBuffer()
 }
 
 
-#if 0
-void BufferView::enterView()
-{
-       pimpl_->enterView();
-}
-
-
-void BufferView::leaveView()
-{
-       pimpl_->leaveView();
-}
-
-
-// Callback for scrollbar slider
-void BufferView::scrollCB(double value)
-{
-       pimpl_->scrollCB(value);
-}
-
-
-void BufferView::workAreaMotionNotify(int x, int y, unsigned int state)
-{
-       pimpl_->workAreaMotionNotify(x, y, state);
-}
-
-
-///  Single-click on work area
-void BufferView::workAreaButtonPress(int xpos, int ypos, unsigned int button)
-{
-       pimpl_->workAreaButtonPress(xpos, ypos, button);
-}
-
-
-void BufferView::doubleClick(int x, int y, unsigned int button) 
-{
-       pimpl_->doubleClick(x, y, button);
-}
-
-
-void BufferView::tripleClick(int x, int y, unsigned int button)
-{
-       pimpl_->tripleClick(x, y, button);
-}
-
-
-void BufferView::workAreaButtonRelease(int x, int y, unsigned int button)
-{
-       pimpl_->workAreaButtonRelease(x, y, button);
-}
-
-
-void BufferView::workAreaExpose()
-{
-       pimpl_->workAreaExpose();
-}
-#endif
-
-
 void BufferView::cursorPrevious(LyXText * text)
 {
        pimpl_->cursorPrevious(text);
@@ -211,9 +159,9 @@ bool BufferView::available() const
 }
 
 
-void BufferView::beforeChange()
+void BufferView::beforeChange(LyXText * text)
 {
-       pimpl_->beforeChange();
+       pimpl_->beforeChange(text);
 }
 
 
@@ -285,7 +233,7 @@ bool BufferView::active() const
 
 int BufferView::workWidth() const
 {
-    return pimpl_->workarea_->workWidth();
+    return pimpl_->workarea_.workWidth();
 }
 
 
@@ -343,3 +291,8 @@ BufferView::UpdateCodes operator|(BufferView::UpdateCodes uc1,
        return static_cast<BufferView::UpdateCodes>
                (static_cast<int>(uc1) | static_cast<int>(uc2));
 }
+
+bool BufferView::Dispatch(kb_action action, string const & argument)
+{
+    return pimpl_->Dispatch(action, argument);
+}