WebBrowser/VirusTotal/VirusTotalWhoisDialog.py

branch
QtWebEngine
changeset 4753
8d2ea02ed785
parent 4631
5c1a96925da4
child 5389
9b1c800daff3
diff -r a3bcc42a82a9 -r 8d2ea02ed785 WebBrowser/VirusTotal/VirusTotalWhoisDialog.py
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/WebBrowser/VirusTotal/VirusTotalWhoisDialog.py	Sat Feb 20 14:34:32 2016 +0100
@@ -0,0 +1,41 @@
+# -*- coding: utf-8 -*-
+
+# Copyright (c) 2015 - 2016 Detlev Offenbach <detlev@die-offenbachs.de>
+#
+
+"""
+Module implementing a dialog to show the 'whois' information.
+"""
+
+from __future__ import unicode_literals
+
+from PyQt5.QtWidgets import QDialog
+
+from .Ui_VirusTotalWhoisDialog import Ui_VirusTotalWhoisDialog
+
+import UI.PixmapCache
+
+
+class VirusTotalWhoisDialog(QDialog, Ui_VirusTotalWhoisDialog):
+    """
+    Class implementing a dialog to show the 'whois' information.
+    """
+    def __init__(self, domain, whois, parent=None):
+        """
+        Constructor
+        
+        @param domain domain name
+        @type str
+        @param whois whois information
+        @type str
+        @param parent reference to the parent widget
+        @type QWidget
+        """
+        super(VirusTotalWhoisDialog, self).__init__(parent)
+        self.setupUi(self)
+        
+        self.headerLabel.setText(
+            self.tr("<b>Whois information for domain {0}</b>").format(domain))
+        self.headerPixmap.setPixmap(
+            UI.PixmapCache.getPixmap("virustotal.png"))
+        self.whoisEdit.setPlainText(whois)

eric ide

mercurial