android: Update app-specific/MIME type icons
[LibreOffice.git] / include / svtools / recorditemwindow.hxx
blob63f46849c469995b2b7f248ce7078b2940710bd4
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 */
10 #pragma once
12 #include <vcl/InterimItemWindow.hxx>
13 #include <svtools/svtdllapi.h>
15 class SVT_DLLPUBLIC RecordItemWindowBase
17 public:
18 RecordItemWindowBase(std::unique_ptr<weld::Entry> xEntry);
19 virtual ~RecordItemWindowBase();
21 void set_text(const OUString& rText) { m_xWidget->set_text(rText); }
22 void set_font(const vcl::Font& rFont) { m_xWidget->set_font(rFont); }
23 void set_help_id(const OUString& rHelpId) { m_xWidget->set_help_id(rHelpId); }
25 protected:
26 std::unique_ptr<weld::Entry> m_xWidget;
28 virtual bool DoKeyInput(const KeyEvent& rEvt);
30 private:
31 virtual void PositionFired(sal_Int64 nRecord);
33 DECL_DLLPRIVATE_LINK(KeyInputHdl, const KeyEvent&, bool);
35 DECL_DLLPRIVATE_LINK(ActivatedHdl, weld::Entry&, bool);
36 // for invalidating our content when losing the focus
37 DECL_DLLPRIVATE_LINK(FocusOutHdl, weld::Widget&, void);
39 void FirePosition(bool bForce);
42 class SVT_DLLPUBLIC RecordItemWindow : public InterimItemWindow, public RecordItemWindowBase
44 public:
45 RecordItemWindow(vcl::Window* pParent);
46 virtual void dispose() override;
47 virtual ~RecordItemWindow() override;
49 protected:
50 virtual bool DoKeyInput(const KeyEvent& rEvt) override;
53 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */