Kaydet (Commit) 14480ef3 authored tarafından Olivier Hallot's avatar Olivier Hallot

Remove deprecated Notes windows in Impress/Draw

This code has not been built for a long time. I suspect it got replaced by the slides panel on the left of simpress main window.
üst fba14229
......@@ -97,7 +97,6 @@ $(eval $(call gb_SrsTarget_add_files,sd/res,\
sd/source/ui/dlg/tpaction.src \
sd/source/ui/dlg/tpoption.src \
sd/source/ui/dlg/vectdlg.src \
sd/source/ui/notes/NotesChildWindow.src \
sd/source/ui/slideshow/slideshow.src \
sd/source/ui/slidesorter/view/SlsResource.src \
sd/source/ui/table/TableDesignPane.src \
......
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
*
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version 3
* only, as published by the Free Software Foundation.
*
* OpenOffice.org is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License version 3 for more details
* (a copy is included in the LICENSE file that accompanied this code).
*
* You should have received a copy of the GNU Lesser General Public License
* version 3 along with OpenOffice.org. If not, see
* <http://www.openoffice.org/license.html>
* for a copy of the LGPLv3 License.
*
************************************************************************/
#define FLT_WIN_NOTES 790
#define NOTES 1
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
*
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version 3
* only, as published by the Free Software Foundation.
*
* OpenOffice.org is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License version 3 for more details
* (a copy is included in the LICENSE file that accompanied this code).
*
* You should have received a copy of the GNU Lesser General Public License
* version 3 along with OpenOffice.org. If not, see
* <http://www.openoffice.org/license.html>
* for a copy of the LGPLv3 License.
*
************************************************************************/
#ifndef SD_NOTES_CHILD_WINDOW_HXX
#define SD_NOTES_CHILD_WINDOW_HXX
#include <sfx2/childwin.hxx>
#define NOTES_CHILD_WINDOW() ( \
static_cast< ::sd::toolpanel::NotesChildWindow*>( \
SfxViewFrame::Current()->GetChildWindow( \
::sd::toolpanel::NotesChildWindow::GetChildWindowId() \
)->GetWindow()))
namespace sd { namespace notes {
class NotesChildWindow
: public SfxChildWindow
{
public:
NotesChildWindow (::Window*, sal_uInt16, SfxBindings*, SfxChildWinInfo*);
virtual ~NotesChildWindow (void);
SFX_DECL_CHILDWINDOW (NotesChildWindow);
};
} } // end of namespaces ::sd::notes
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
This diff is collapsed.
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
*
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version 3
* only, as published by the Free Software Foundation.
*
* OpenOffice.org is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License version 3 for more details
* (a copy is included in the LICENSE file that accompanied this code).
*
* You should have received a copy of the GNU Lesser General Public License
* version 3 along with OpenOffice.org. If not, see
* <http://www.openoffice.org/license.html>
* for a copy of the LGPLv3 License.
*
************************************************************************/
#ifndef SD_EDIT_WINDOW_HXX
#define SD_EDIT_WINDOW_HXX
#include <vcl/window.hxx>
#include <svtools/transfer.hxx>
#include <vcl/timer.hxx>
#include <editeng/editdata.hxx>
#include <svtools/colorcfg.hxx>
class EditEngine;
class EditStatus;
class EditView;
class Menu;
class ScrollBar;
class ScrollBarBox;
class SfxItemPool;
class Timer;
namespace sd { namespace notes {
class EditWindow
: public Window,
public DropTargetHelper
{
public:
EditWindow (Window* pParentWindow, SfxItemPool* pItemPool);
~EditWindow (void);
void InsertText (const String &rText);
using Window::GetText;
private:
EditView* mpEditView;
EditEngine* mpEditEngine;
SfxItemPool* mpEditEngineItemPool;
ScrollBar* mpHorizontalScrollBar;
ScrollBar* mpVerticalScrollBar;
ScrollBarBox* mpScrollBox;
Timer maModifyTimer;
Timer maCursorMoveTimer;
ESelection maOldSelection;
virtual void KeyInput(const KeyEvent& rKEvt);
virtual void Command(const CommandEvent& rCEvt);
DECL_LINK(MenuSelectHdl, Menu *);
virtual void DataChanged( const DataChangedEvent& );
virtual void Resize();
virtual void MouseMove(const MouseEvent &rEvt);
virtual void MouseButtonUp(const MouseEvent &rEvt);
virtual void MouseButtonDown(const MouseEvent &rEvt);
virtual sal_Int8 AcceptDrop( const AcceptDropEvent& rEvt );
virtual sal_Int8 ExecuteDrop( const ExecuteDropEvent& rEvt );
virtual void Paint(const Rectangle& rRect);
DECL_LINK(EditStatusHdl ,EditStatus *);
DECL_LINK(ScrollHdl, ScrollBar *);
void CreateEditView();
Rectangle AdjustScrollBars();
void SetScrollBarRanges();
void InitScrollBars();
// SmDocShell * GetDoc();
// SmViewShell * GetView();
EditView* GetEditView (void);
EditEngine* GetEditEngine (void);
EditEngine* CreateEditEngine (void);
// Window
virtual void SetText(const XubString &rText);
virtual XubString GetText();
virtual void GetFocus();
virtual void LoseFocus();
ESelection GetSelection() const;
void SetSelection(const ESelection &rSel);
sal_Bool IsEmpty() const;
sal_Bool IsSelected() const;
sal_Bool IsAllSelected() const;
void Cut();
void Copy();
void Paste();
void Delete();
void SelectAll();
void MarkError(const Point &rPos);
void SelNextMark();
void SelPrevMark();
sal_Bool HasMark(const String &rText) const;
void ApplyColorConfigValues( const svtools::ColorConfig &rColorCfg );
};
} } // end of namespace ::sd::notes
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
*
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version 3
* only, as published by the Free Software Foundation.
*
* OpenOffice.org is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License version 3 for more details
* (a copy is included in the LICENSE file that accompanied this code).
*
* You should have received a copy of the GNU Lesser General Public License
* version 3 along with OpenOffice.org. If not, see
* <http://www.openoffice.org/license.html>
* for a copy of the LGPLv3 License.
*
************************************************************************/
#include "NotesChildWindow.hxx"
#include "NotesDockingWindow.hxx"
#include "sdresid.hxx"
#include "app.hrc"
#include "sfx2/app.hxx"
namespace sd { namespace notes {
NotesChildWindow::NotesChildWindow (
::Window* _pParent,
sal_uInt16 nId,
SfxBindings* pBindings,
SfxChildWinInfo* pInfo)
: SfxChildWindow (_pParent, nId)
{
pWindow = new NotesDockingWindow (pBindings, this, _pParent);
eChildAlignment = SFX_ALIGN_BOTTOM;
static_cast<SfxDockingWindow*>(pWindow)->Initialize(pInfo);
};
NotesChildWindow::~NotesChildWindow()
{}
SFX_IMPL_DOCKINGWINDOW(NotesChildWindow, SID_NOTES_WINDOW)
} } // end of namespace ::sd::notes
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
*
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version 3
* only, as published by the Free Software Foundation.
*
* OpenOffice.org is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License version 3 for more details
* (a copy is included in the LICENSE file that accompanied this code).
*
* You should have received a copy of the GNU Lesser General Public License
* version 3 along with OpenOffice.org. If not, see
* <http://www.openoffice.org/license.html>
* for a copy of the LGPLv3 License.
*
************************************************************************/
#include "app.hrc"
#include "NotesChildWindow.hrc"
#include "sdcommands.h"
DockingWindow FLT_WIN_NOTES
{
HelpID = CMD_SID_NOTES_WINDOW ;
Border = TRUE ;
Hide = FALSE ;
SVLook = TRUE ;
Sizeable = TRUE ;
Moveable = TRUE ;
Closeable = TRUE ;
Zoomable = TRUE ;
Dockable = TRUE ;
EnableResizing = TRUE ;
Size = MAP_APPFONT ( 140 , 120 ) ;
Text [ en-US ] = "Notes Window" ;
};
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
*
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version 3
* only, as published by the Free Software Foundation.
*
* OpenOffice.org is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License version 3 for more details
* (a copy is included in the LICENSE file that accompanied this code).
*
* You should have received a copy of the GNU Lesser General Public License
* version 3 along with OpenOffice.org. If not, see
* <http://www.openoffice.org/license.html>
* for a copy of the LGPLv3 License.
*
************************************************************************/
#include "NotesDockingWindow.hxx"
#include "NotesChildWindow.hrc"
#include "EditWindow.hxx"
#include "TextLogger.hxx"
#include <svx/dlgctrl.hxx>
#include <sfx2/bindings.hxx>
#include <sfx2/dispatch.hxx>
#include <sfx2/viewfrm.hxx>
#include "DrawViewShell.hxx"
#include "drawdoc.hxx"
#include "sdresid.hxx"
#include "ViewShellBase.hxx"
namespace sd { namespace notes {
NotesDockingWindow::NotesDockingWindow (
SfxBindings *_pBindings,
SfxChildWindow *pChildWindow,
Window* _pParent)
: SfxDockingWindow (_pBindings, pChildWindow, _pParent,
SdResId(FLT_WIN_NOTES))
{
ViewShellBase* pBase = ViewShellBase::GetViewShellBase (
_pBindings->GetDispatcher()->GetFrame());
if (pBase != NULL)
{
SdDrawDocument* pDocument = pBase->GetDocument();
mpEditWindow = new EditWindow (this, &pDocument->GetPool());
mpEditWindow->Show();
TextLogger::Instance().ConnectToEditWindow (mpEditWindow);
}
}
NotesDockingWindow::~NotesDockingWindow (void)
{
delete mpEditWindow;
}
void NotesDockingWindow::Paint (const Rectangle& rBoundingBox)
{
SfxDockingWindow::Paint (rBoundingBox);
Size aWindowSize (GetOutputSizePixel());
Rectangle aBBox;
Point aPosition(10,aWindowSize.Height()/2);
String aString (UniString::CreateFromAscii("Bottom Panel Docking Window"));
if (GetTextBoundRect (aBBox, aString))
aPosition = Point (
(aWindowSize.Width()-aBBox.GetWidth())/2,
(aWindowSize.Height()-aBBox.GetHeight())/2);
DrawText (aPosition, aString);
}
void NotesDockingWindow::Resize (void)
{
SfxDockingWindow::Resize();
Size aWinSize (GetOutputSizePixel());
if (mpEditWindow != NULL)
{
mpEditWindow->SetPosSizePixel (
Point(0,0),
aWinSize);
}
}
} } // end of namespace ::sd::notes
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
*
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version 3
* only, as published by the Free Software Foundation.
*
* OpenOffice.org is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License version 3 for more details
* (a copy is included in the LICENSE file that accompanied this code).
*
* You should have received a copy of the GNU Lesser General Public License
* version 3 along with OpenOffice.org. If not, see
* <http://www.openoffice.org/license.html>
* for a copy of the LGPLv3 License.
*
************************************************************************/
#ifndef SD_TPV_BOTTOM_DOCKING_WINDOW_HXX_
#define SD_TPV_BOTTOM_DOCKING_WINDOW_HXX_
#include <sfx2/dockwin.hxx>
namespace sd { namespace notes {
class EditWindow;
class NotesDockingWindow
: public SfxDockingWindow
{
public:
NotesDockingWindow (
SfxBindings *pBindings,
SfxChildWindow *pChildWindow,
Window* pParent);
virtual ~NotesDockingWindow (void);
virtual void Paint (const Rectangle& rBoundingBox);
virtual void Resize (void);
private:
EditWindow* mpEditWindow;
};
} } // end of namespace ::sd::notes
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
*
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version 3
* only, as published by the Free Software Foundation.
*
* OpenOffice.org is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License version 3 for more details
* (a copy is included in the LICENSE file that accompanied this code).
*
* You should have received a copy of the GNU Lesser General Public License
* version 3 along with OpenOffice.org. If not, see
* <http://www.openoffice.org/license.html>
* for a copy of the LGPLv3 License.
*
************************************************************************/
#include "TextLogger.hxx"
#include "EditWindow.hxx"
#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
namespace sd { namespace notes {
TextLogger* TextLogger::spInstance = NULL;
TextLogger& TextLogger::Instance (void)
{
if (spInstance == NULL)
{
SolarMutexGuard aGuard;
if (spInstance == NULL)
spInstance = new TextLogger ();
}
return *spInstance;
}
TextLogger::TextLogger (void)
: mpEditWindow (NULL)
{
}
void TextLogger::AppendText (const char* sText)
{
OSL_TRACE("%s", sText);
if (mpEditWindow != NULL)
mpEditWindow->InsertText (UniString::CreateFromAscii(sText));
}
void TextLogger::AppendText (const String& sText)
{
rtl::OString s(rtl::OUStringToOString(sText, RTL_TEXTENCODING_ISO_8859_1));
OSL_TRACE("%s", s.getStr());
if (mpEditWindow != NULL)
mpEditWindow->InsertText (sText);
}
void TextLogger::AppendNumber (long int nValue)
{
AppendText (String::CreateFromInt32(nValue));
}
void TextLogger::ConnectToEditWindow (EditWindow* pEditWindow)
{
if (mpEditWindow != pEditWindow)
{
if (pEditWindow != NULL)
pEditWindow->AddEventListener(
LINK(this, TextLogger, WindowEventHandler));
else
mpEditWindow->RemoveEventListener(
LINK(this, TextLogger, WindowEventHandler));
mpEditWindow = pEditWindow;
}
}
IMPL_LINK(TextLogger, WindowEventHandler, VclWindowEvent*, pEvent)
{
if (pEvent != NULL)
{
DBG_ASSERT(static_cast<VclWindowEvent*>(pEvent)->GetWindow()
== mpEditWindow,
"TextLogger: received event from unknown window");
switch (pEvent->GetId())
{
case VCLEVENT_WINDOW_CLOSE:
case VCLEVENT_OBJECT_DYING:
mpEditWindow = NULL;
break;
}
}
return sal_True;
}
} } // end of namespace ::sd::notes
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
......@@ -46,7 +46,6 @@
#include "DrawDocShell.hxx"
#include <sfx2/app.hxx>
#include "PaneChildWindows.hxx"
#include "NotesChildWindow.hxx"
#include "ViewShellManager.hxx"
#include "DrawController.hxx"
#include "FrameView.hxx"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment