Christophe Dumez
16 years ago
8 changed files with 126 additions and 10 deletions
@ -0,0 +1,58 @@ |
|||||||
|
<ui version="4.0" > |
||||||
|
<class>ConsoleDlg</class> |
||||||
|
<widget class="QDialog" name="ConsoleDlg" > |
||||||
|
<property name="geometry" > |
||||||
|
<rect> |
||||||
|
<x>0</x> |
||||||
|
<y>0</y> |
||||||
|
<width>512</width> |
||||||
|
<height>497</height> |
||||||
|
</rect> |
||||||
|
</property> |
||||||
|
<property name="windowTitle" > |
||||||
|
<string>qBittorrent console</string> |
||||||
|
</property> |
||||||
|
<property name="windowIcon" > |
||||||
|
<iconset resource="icons.qrc" >:/Icons/log.png</iconset> |
||||||
|
</property> |
||||||
|
<layout class="QVBoxLayout" > |
||||||
|
<item> |
||||||
|
<widget class="QTabWidget" name="tabConsole" > |
||||||
|
<property name="currentIndex" > |
||||||
|
<number>0</number> |
||||||
|
</property> |
||||||
|
<widget class="QWidget" name="tab" > |
||||||
|
<attribute name="title" > |
||||||
|
<string>General</string> |
||||||
|
</attribute> |
||||||
|
<attribute name="icon" > |
||||||
|
<iconset resource="icons.qrc" >:/Icons/log.png</iconset> |
||||||
|
</attribute> |
||||||
|
<layout class="QVBoxLayout" > |
||||||
|
<item> |
||||||
|
<widget class="QTextBrowser" name="textConsole" /> |
||||||
|
</item> |
||||||
|
</layout> |
||||||
|
</widget> |
||||||
|
<widget class="QWidget" name="tab_2" > |
||||||
|
<attribute name="title" > |
||||||
|
<string>Blocked IPs</string> |
||||||
|
</attribute> |
||||||
|
<attribute name="icon" > |
||||||
|
<iconset resource="icons.qrc" >:/Icons/filter.png</iconset> |
||||||
|
</attribute> |
||||||
|
<layout class="QVBoxLayout" > |
||||||
|
<item> |
||||||
|
<widget class="QTextBrowser" name="textBannedPeers" /> |
||||||
|
</item> |
||||||
|
</layout> |
||||||
|
</widget> |
||||||
|
</widget> |
||||||
|
</item> |
||||||
|
</layout> |
||||||
|
</widget> |
||||||
|
<resources> |
||||||
|
<include location="icons.qrc" /> |
||||||
|
</resources> |
||||||
|
<connections/> |
||||||
|
</ui> |
@ -0,0 +1,50 @@ |
|||||||
|
/*
|
||||||
|
* Bittorrent Client using Qt4 and libtorrent. |
||||||
|
* Copyright (C) 2006 Christophe Dumez |
||||||
|
* |
||||||
|
* This program is free software; you can redistribute it and/or |
||||||
|
* modify it under the terms of the GNU General Public License |
||||||
|
* as published by the Free Software Foundation; either version 2 |
||||||
|
* of the License, or (at your option) any later version. |
||||||
|
* |
||||||
|
* This program is distributed in the hope that it will be useful, |
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||||
|
* GNU General Public License for more details. |
||||||
|
* |
||||||
|
* You should have received a copy of the GNU General Public License |
||||||
|
* along with this program; if not, write to the Free Software |
||||||
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
||||||
|
* |
||||||
|
* Contact : chris@qbittorrent.org |
||||||
|
*/ |
||||||
|
|
||||||
|
#ifndef CONSOLE_H |
||||||
|
#define CONSOLE_H |
||||||
|
|
||||||
|
#include "bittorrent.h" |
||||||
|
#include "ui_console.h" |
||||||
|
|
||||||
|
using namespace libtorrent; |
||||||
|
|
||||||
|
class consoleDlg : public QDialog, private Ui_ConsoleDlg{ |
||||||
|
Q_OBJECT |
||||||
|
|
||||||
|
private: |
||||||
|
bittorrent *BTSession; |
||||||
|
|
||||||
|
public: |
||||||
|
consoleDlg(QWidget *parent, bittorrent* _BTSession) : QDialog(parent) { |
||||||
|
setupUi(this); |
||||||
|
setAttribute(Qt::WA_DeleteOnClose); |
||||||
|
BTSession = _BTSession; |
||||||
|
textConsole->setHtml(BTSession->getConsoleMessages().join("<br>")); |
||||||
|
textBannedPeers->setHtml(BTSession->getPeerBanMessages().join("<br>")); |
||||||
|
show(); |
||||||
|
} |
||||||
|
|
||||||
|
~consoleDlg() {} |
||||||
|
|
||||||
|
}; |
||||||
|
|
||||||
|
#endif |
Loading…
Reference in new issue