mirror of
https://github.com/zealdocs/zeal.git
synced 2024-08-17 02:00:25 +03:00
style: use Q_DISABLE_COPY macro consistently
This commit is contained in:
parent
cfb1dc661e
commit
3fdeb66164
@ -36,19 +36,14 @@ class View;
|
||||
class Container : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY(Container)
|
||||
public:
|
||||
explicit Container(QWidget *parent = nullptr);
|
||||
~Container() override;
|
||||
|
||||
void addView(View *view);
|
||||
|
||||
public slots:
|
||||
|
||||
signals:
|
||||
|
||||
private:
|
||||
Q_DISABLE_COPY(Container)
|
||||
|
||||
QSplitter *m_splitter = nullptr;
|
||||
|
||||
QList<View *> m_views;
|
||||
|
@ -33,13 +33,12 @@ class ViewProvider;
|
||||
class ProxyView final : public View
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY(ProxyView)
|
||||
public:
|
||||
explicit ProxyView(ViewProvider *provider, QString id = QString(), QWidget *parent = nullptr);
|
||||
~ProxyView() override;
|
||||
|
||||
private:
|
||||
Q_DISABLE_COPY(ProxyView)
|
||||
|
||||
void clearCurrentView();
|
||||
|
||||
ViewProvider *m_viewProvider = nullptr;
|
||||
|
@ -31,11 +31,9 @@ namespace Sidebar {
|
||||
class View : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY(View)
|
||||
public:
|
||||
explicit View(QWidget *parent = nullptr);
|
||||
|
||||
private:
|
||||
Q_DISABLE_COPY(View)
|
||||
};
|
||||
|
||||
} // namespace Sidebar
|
||||
|
@ -33,6 +33,7 @@ class View;
|
||||
class ViewProvider : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY(ViewProvider)
|
||||
public:
|
||||
explicit ViewProvider(QObject *parent = nullptr);
|
||||
|
||||
@ -40,9 +41,6 @@ public:
|
||||
|
||||
signals:
|
||||
void viewChanged();
|
||||
|
||||
private:
|
||||
Q_DISABLE_COPY(ViewProvider)
|
||||
};
|
||||
|
||||
} // namespace Sidebar
|
||||
|
@ -47,6 +47,7 @@ class SearchSidebar;
|
||||
class BrowserTab : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY(BrowserTab)
|
||||
public:
|
||||
explicit BrowserTab(QWidget *parent = nullptr);
|
||||
BrowserTab *clone(QWidget *parent = nullptr) const;
|
||||
@ -64,7 +65,6 @@ signals:
|
||||
void titleChanged(const QString &title);
|
||||
|
||||
private:
|
||||
Q_DISABLE_COPY(BrowserTab)
|
||||
QIcon docsetIcon(const QUrl &url) const;
|
||||
|
||||
// Widgets.
|
||||
|
@ -48,6 +48,7 @@ class SearchEdit;
|
||||
class SearchSidebar final : public Sidebar::View
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY(SearchSidebar)
|
||||
public:
|
||||
explicit SearchSidebar(QWidget *parent = nullptr);
|
||||
SearchSidebar *clone(QWidget *parent = nullptr) const;
|
||||
@ -73,7 +74,6 @@ protected:
|
||||
void showEvent(QShowEvent *event) override;
|
||||
|
||||
private:
|
||||
Q_DISABLE_COPY(SearchSidebar)
|
||||
explicit SearchSidebar(const SearchSidebar *other, QWidget *parent = nullptr);
|
||||
void setTreeViewModel(QAbstractItemModel *model, bool isRootDecorated);
|
||||
|
||||
|
@ -33,14 +33,13 @@ class MainWindow;
|
||||
class SidebarViewProvider : public Sidebar::ViewProvider
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY(SidebarViewProvider)
|
||||
public:
|
||||
explicit SidebarViewProvider(MainWindow *mainWindow);
|
||||
|
||||
Sidebar::View *view(const QString &id = QString()) const override;
|
||||
|
||||
private:
|
||||
Q_DISABLE_COPY(SidebarViewProvider)
|
||||
|
||||
MainWindow *m_mainWindow = nullptr;
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user