Mod: Use override etc 2
This commit is contained in:
@@ -80,7 +80,7 @@ public:
|
||||
initialize("This module is the Web module."); // register with Python
|
||||
}
|
||||
|
||||
virtual ~Module() {}
|
||||
~Module() override {}
|
||||
|
||||
private:
|
||||
Py::Object startServer(const Py::Tuple& args)
|
||||
|
||||
@@ -51,8 +51,8 @@ class FirewallPython : public Firewall
|
||||
{
|
||||
public:
|
||||
FirewallPython(const Py::Object&);
|
||||
virtual ~FirewallPython();
|
||||
virtual bool filter(const QByteArray&) const;
|
||||
~FirewallPython() override;
|
||||
bool filter(const QByteArray&) const override;
|
||||
|
||||
private:
|
||||
Py::Object obj;
|
||||
@@ -62,7 +62,7 @@ class ServerEvent : public QEvent
|
||||
{
|
||||
public:
|
||||
ServerEvent(QTcpSocket* socket, const QByteArray&);
|
||||
~ServerEvent();
|
||||
~ServerEvent() override;
|
||||
|
||||
QTcpSocket* socket() const;
|
||||
const QByteArray& request() const;
|
||||
@@ -83,8 +83,8 @@ public:
|
||||
AppServer(bool direct = false, QObject* parent = nullptr);
|
||||
|
||||
protected:
|
||||
void incomingConnection(qintptr socket);
|
||||
void customEvent(QEvent* e);
|
||||
void incomingConnection(qintptr socket) override;
|
||||
void customEvent(QEvent* e) override;
|
||||
|
||||
private:
|
||||
std::string handleRequest(QByteArray);
|
||||
|
||||
@@ -70,7 +70,7 @@ public:
|
||||
initialize("This module is the WebGui module."); // register with Python
|
||||
}
|
||||
|
||||
virtual ~Module() {}
|
||||
~Module() override {}
|
||||
|
||||
private:
|
||||
Py::Object openBrowser(const Py::Tuple& args)
|
||||
|
||||
@@ -91,7 +91,7 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void interceptRequest(QWebEngineUrlRequestInfo &info)
|
||||
void interceptRequest(QWebEngineUrlRequestInfo &info) override
|
||||
{
|
||||
// do something with this resource, click or get img for example
|
||||
if (info.navigationType() == QWebEngineUrlRequestInfo::NavigationTypeLink) {
|
||||
@@ -157,10 +157,10 @@ public:
|
||||
static void init_type(); // announce properties and methods
|
||||
|
||||
BrowserViewPy(BrowserView* view);
|
||||
~BrowserViewPy();
|
||||
~BrowserViewPy() override;
|
||||
|
||||
Py::Object repr();
|
||||
Py::Object getattr(const char *);
|
||||
Py::Object repr() override;
|
||||
Py::Object getattr(const char *) override;
|
||||
Py::Object cast_to_base(const Py::Tuple&);
|
||||
|
||||
Py::Object setHtml(const Py::Tuple&);
|
||||
|
||||
@@ -59,9 +59,9 @@ public:
|
||||
WebView(QWidget *parent = nullptr);
|
||||
|
||||
protected:
|
||||
void mousePressEvent(QMouseEvent *event);
|
||||
void wheelEvent(QWheelEvent *event);
|
||||
void contextMenuEvent(QContextMenuEvent *event);
|
||||
void mousePressEvent(QMouseEvent *event) override;
|
||||
void wheelEvent(QWheelEvent *event) override;
|
||||
void contextMenuEvent(QContextMenuEvent *event) override;
|
||||
|
||||
private Q_SLOTS:
|
||||
void triggerContextMenuAction(int);
|
||||
@@ -85,7 +85,7 @@ class WebGuiExport BrowserView : public Gui::MDIView,
|
||||
|
||||
public:
|
||||
BrowserView(QWidget* parent);
|
||||
~BrowserView();
|
||||
~BrowserView() override;
|
||||
|
||||
void load(const char* URL);
|
||||
void load(const QUrl & url);
|
||||
@@ -93,15 +93,15 @@ public:
|
||||
void stop();
|
||||
QUrl url() const;
|
||||
|
||||
void OnChange(Base::Subject<const char*> &rCaller,const char* rcReason);
|
||||
void OnChange(Base::Subject<const char*> &rCaller,const char* rcReason) override;
|
||||
|
||||
const char *getName() const {return "BrowserView";}
|
||||
virtual PyObject *getPyObject();
|
||||
const char *getName() const override {return "BrowserView";}
|
||||
PyObject *getPyObject() override;
|
||||
|
||||
bool onMsg(const char* pMsg,const char** ppReturn);
|
||||
bool onHasMsg(const char* pMsg) const;
|
||||
bool onMsg(const char* pMsg,const char** ppReturn) override;
|
||||
bool onHasMsg(const char* pMsg) const override;
|
||||
|
||||
bool canClose ();
|
||||
bool canClose () override;
|
||||
|
||||
#ifdef QTWEBENGINE
|
||||
public Q_SLOTS:
|
||||
@@ -145,10 +145,10 @@ class UrlWidget : public QLineEdit
|
||||
BrowserView *m_view;
|
||||
public:
|
||||
explicit UrlWidget(BrowserView *view);
|
||||
~UrlWidget();
|
||||
~UrlWidget() override;
|
||||
void display();
|
||||
protected:
|
||||
void keyPressEvent(QKeyEvent *keyEvt);
|
||||
void keyPressEvent(QKeyEvent *keyEvt) override;
|
||||
};
|
||||
|
||||
} // namespace WebGui
|
||||
|
||||
@@ -39,8 +39,8 @@ namespace WebGui {
|
||||
|
||||
public:
|
||||
FcCookieJar(QObject* parent = nullptr);
|
||||
virtual ~FcCookieJar();
|
||||
virtual bool setCookiesFromUrl(const QList<QNetworkCookie>&, const QUrl&);
|
||||
~FcCookieJar() override;
|
||||
bool setCookiesFromUrl(const QList<QNetworkCookie>&, const QUrl&) override;
|
||||
|
||||
public Q_SLOTS:
|
||||
void scheduleSaveToDisk();
|
||||
|
||||
@@ -37,20 +37,20 @@ class Workbench : public Gui::StdWorkbench
|
||||
|
||||
public:
|
||||
Workbench();
|
||||
virtual ~Workbench();
|
||||
~Workbench() override;
|
||||
|
||||
/** Defines the standard context menu. */
|
||||
virtual void setupContextMenu(const char* recipient,Gui::MenuItem*) const;
|
||||
void setupContextMenu(const char* recipient,Gui::MenuItem*) const override;
|
||||
|
||||
protected:
|
||||
/** Defines the standard menus. */
|
||||
virtual Gui::MenuItem* setupMenuBar() const;
|
||||
Gui::MenuItem* setupMenuBar() const override;
|
||||
/** Defines the standard toolbars. */
|
||||
virtual Gui::ToolBarItem* setupToolBars() const;
|
||||
Gui::ToolBarItem* setupToolBars() const override;
|
||||
/** Defines the standard command bars. */
|
||||
virtual Gui::ToolBarItem* setupCommandBars() const;
|
||||
Gui::ToolBarItem* setupCommandBars() const override;
|
||||
/** Returns a DockWindowItems structure of dock windows this workbench. */
|
||||
virtual Gui::DockWindowItems* setupDockWindows() const;
|
||||
Gui::DockWindowItems* setupDockWindows() const override;
|
||||
|
||||
|
||||
}; // namespace WebGui
|
||||
|
||||
Reference in New Issue
Block a user