MythTV master
Public Member Functions | Protected Slots | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
MythWebEngineView Class Reference

Subclass of QWebEngineView. More...

#include <libmythui/mythuiwebbrowser.h>

Inheritance diagram for MythWebEngineView:
[legend]
Collaboration diagram for MythWebEngineView:
[legend]

Public Member Functions

 MythWebEngineView (QWidget *parent, MythUIWebBrowser *parentBrowser)
 
 ~MythWebEngineView (void) override
 
bool eventFilter (QObject *obj, QEvent *event) override
 
void customEvent (QEvent *e) override
 

Protected Slots

QWebEngineView * createWindow (QWebEnginePage::WebWindowType type) override
 

Private Member Functions

void sendKeyPress (int key, Qt::KeyboardModifiers modifiers, const QString &text=QString())
 
bool handleKeyPress (QKeyEvent *event)
 
void showDownloadMenu (void)
 
void openBusyPopup (const QString &message)
 
void closeBusyPopup (void)
 
QString getReplyMimetype (void)
 

Static Private Member Functions

static bool isMusicFile (const QString &extension, const QString &mimetype)
 
static bool isVideoFile (const QString &extension, const QString &mimetype)
 
static QString getExtensionForMimetype (const QString &mimetype)
 

Private Attributes

QWebEnginePage * m_webpage {nullptr}
 
MythUIWebBrowserm_parentBrowser {nullptr}
 
QWebEngineProfile * m_profile {nullptr}
 
QNetworkRequest m_downloadRequest
 
QNetworkReply * m_downloadReply {nullptr}
 
MythUIBusyDialogm_busyPopup {nullptr}
 
bool m_downloadAndPlay {false}
 

Detailed Description

Subclass of QWebEngineView.

Note
allows us to intercept keypresses

Definition at line 29 of file mythuiwebbrowser.h.

Constructor & Destructor Documentation

◆ MythWebEngineView()

MythWebEngineView::MythWebEngineView ( QWidget *  parent,
MythUIWebBrowser parentBrowser 
)

Definition at line 90 of file mythuiwebbrowser.cpp.

◆ ~MythWebEngineView()

MythWebEngineView::~MythWebEngineView ( void  )
override

Definition at line 104 of file mythuiwebbrowser.cpp.

Member Function Documentation

◆ closeBusyPopup()

void MythWebEngineView::closeBusyPopup ( void  )
private

Definition at line 268 of file mythuiwebbrowser.cpp.

Referenced by customEvent().

◆ createWindow

QWebEngineView * MythWebEngineView::createWindow ( QWebEnginePage::WebWindowType  type)
overrideprotectedslot

Definition at line 465 of file mythuiwebbrowser.cpp.

◆ customEvent()

void MythWebEngineView::customEvent ( QEvent *  e)
override

Definition at line 276 of file mythuiwebbrowser.cpp.

◆ eventFilter()

bool MythWebEngineView::eventFilter ( QObject *  obj,
QEvent *  event 
)
override

Definition at line 110 of file mythuiwebbrowser.cpp.

◆ getExtensionForMimetype()

QString MythWebEngineView::getExtensionForMimetype ( const QString &  mimetype)
staticprivate

Definition at line 408 of file mythuiwebbrowser.cpp.

◆ getReplyMimetype()

QString MythWebEngineView::getReplyMimetype ( void  )
private

Definition at line 451 of file mythuiwebbrowser.cpp.

Referenced by customEvent(), and showDownloadMenu().

◆ handleKeyPress()

bool MythWebEngineView::handleKeyPress ( QKeyEvent *  event)
private

Definition at line 148 of file mythuiwebbrowser.cpp.

Referenced by eventFilter().

◆ isMusicFile()

bool MythWebEngineView::isMusicFile ( const QString &  extension,
const QString &  mimetype 
)
staticprivate

Definition at line 421 of file mythuiwebbrowser.cpp.

Referenced by customEvent(), and showDownloadMenu().

◆ isVideoFile()

bool MythWebEngineView::isVideoFile ( const QString &  extension,
const QString &  mimetype 
)
staticprivate

Definition at line 436 of file mythuiwebbrowser.cpp.

Referenced by customEvent(), and showDownloadMenu().

◆ openBusyPopup()

void MythWebEngineView::openBusyPopup ( const QString &  message)
private

Definition at line 251 of file mythuiwebbrowser.cpp.

◆ sendKeyPress()

void MythWebEngineView::sendKeyPress ( int  key,
Qt::KeyboardModifiers  modifiers,
const QString &  text = QString() 
)
private

Definition at line 136 of file mythuiwebbrowser.cpp.

Referenced by handleKeyPress().

◆ showDownloadMenu()

void MythWebEngineView::showDownloadMenu ( void  )
private

Definition at line 376 of file mythuiwebbrowser.cpp.

Member Data Documentation

◆ m_busyPopup

MythUIBusyDialog* MythWebEngineView::m_busyPopup {nullptr}
private

Definition at line 62 of file mythuiwebbrowser.h.

Referenced by closeBusyPopup(), and openBusyPopup().

◆ m_downloadAndPlay

bool MythWebEngineView::m_downloadAndPlay {false}
private

Definition at line 63 of file mythuiwebbrowser.h.

Referenced by customEvent().

◆ m_downloadReply

QNetworkReply* MythWebEngineView::m_downloadReply {nullptr}
private

Definition at line 61 of file mythuiwebbrowser.h.

Referenced by getReplyMimetype().

◆ m_downloadRequest

QNetworkRequest MythWebEngineView::m_downloadRequest
private

Definition at line 60 of file mythuiwebbrowser.h.

Referenced by customEvent(), and showDownloadMenu().

◆ m_parentBrowser

MythUIWebBrowser* MythWebEngineView::m_parentBrowser {nullptr}
private

Definition at line 58 of file mythuiwebbrowser.h.

Referenced by customEvent(), and handleKeyPress().

◆ m_profile

QWebEngineProfile* MythWebEngineView::m_profile {nullptr}
private

Definition at line 59 of file mythuiwebbrowser.h.

Referenced by MythWebEngineView(), and ~MythWebEngineView().

◆ m_webpage

QWebEnginePage* MythWebEngineView::m_webpage {nullptr}
private

Definition at line 57 of file mythuiwebbrowser.h.

Referenced by MythWebEngineView(), and ~MythWebEngineView().


The documentation for this class was generated from the following files: