Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Oct 2, 2020. It is now read-only.

change PySide to PyQt5 #10

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions ArchitectureDialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.

from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from PyQt5.QtWidgets import *


class ArchitectureDialog(QDialog):
Expand Down
4 changes: 2 additions & 2 deletions AssembleDialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.

from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from Fonts import *
from TextEditor import *
import nasm
Expand Down
6 changes: 3 additions & 3 deletions DisassemblerView.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def __init__(self, view):
self.highlight_token = view.highlight_token

class DisassemblerView(QAbstractScrollArea):
statusUpdated = Signal(QWidget, name="statusUpdated")
statusUpdated = pyqtSignal(QWidget, name="statusUpdated")

def __init__(self, data, filename, view, parent):
super(DisassemblerView, self).__init__(parent)
Expand Down Expand Up @@ -288,8 +288,8 @@ def paintEvent(self, event):
for edge in block.edges:
p.setPen(edge.color)
p.setBrush(edge.color)
p.drawPolyline(edge.polyline)
p.drawConvexPolygon(edge.arrow)
p.drawPolyline(QPolygon(edge.polyline))
p.drawConvexPolygon(QPolygon(edge.arrow))

def isMouseEventInBlock(self, event):
# Convert coordinates to system used in blocks
Expand Down
5 changes: 3 additions & 2 deletions FindDialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.

from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from PyQt5.QtWidgets import *
import re
import sys

Expand Down
4 changes: 2 additions & 2 deletions Fonts.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.

import sys
from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *

monospaceFont = None
lineSpacing = None
Expand Down
10 changes: 6 additions & 4 deletions HelpView.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,12 @@

import sys
import os
from PySide.QtCore import *
from PySide.QtGui import *
from PySide.QtWebKit import *
from PySide.QtNetwork import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from PyQt5.QtWebKit import *
from PyQt5.QtNetwork import *
from PyQt5.QtWidgets import *
from PyQt5.QtWebKitWidgets import QWebView
from View import *


Expand Down
6 changes: 3 additions & 3 deletions HexEditor.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.

import sys
from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from Fonts import *
from View import *
from BinaryData import *
Expand All @@ -31,7 +31,7 @@ def __init__(self, view):
self.ascii = view.cursorAscii

class HexEditor(QAbstractScrollArea):
statusUpdated = Signal(QWidget, name="statusUpdated")
statusUpdated = pyqtSignal(QWidget, name="statusUpdated")

def __init__(self, data, filename, view, parent):
super(HexEditor, self).__init__(parent)
Expand Down
5 changes: 3 additions & 2 deletions Preferences.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.

from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from PyQt5.QtWidgets import *
from Fonts import *


Expand Down
9 changes: 5 additions & 4 deletions PythonConsole.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.

from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from PyQt5.QtWidgets import *
from Fonts import *
import code
import sys
Expand Down Expand Up @@ -163,8 +164,8 @@ def run(self):
self.done.set()

class PythonConsoleLineEdit(QLineEdit):
prevHistory = Signal(())
nextHistory = Signal(())
prevHistory = pyqtSignal(())
nextHistory = pyqtSignal(())

def __init__(self, *args):
super(PythonConsoleLineEdit, self).__init__(*args)
Expand Down
4 changes: 2 additions & 2 deletions RunWindow.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.

import shlex
from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from TerminalView import *


Expand Down
5 changes: 3 additions & 2 deletions TerminalView.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,9 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.

import sys
from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from PyQt5.QtWidgets import *
from TerminalProcess import *
from Fonts import *

Expand Down
6 changes: 3 additions & 3 deletions TextEditor.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@

import sys
import os
from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from Fonts import *
from View import *
from BinaryData import *
Expand All @@ -41,7 +41,7 @@ def __init__(self, view):


class TextEditor(QAbstractScrollArea):
statusUpdated = Signal(QWidget, name="statusUpdated")
statusUpdated = pyqtSignal(QWidget, name="statusUpdated")

def __init__(self, data, filename, view, parent):
super(TextEditor, self).__init__(parent)
Expand Down
4 changes: 2 additions & 2 deletions Threads.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.

from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
import thread
import threading

Expand Down
5 changes: 3 additions & 2 deletions Transform.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.

from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from PyQt5.QtWidgets import *
from Crypto.Cipher import AES
from Crypto.Cipher import Blowfish
from Crypto.Cipher import CAST
Expand Down
4 changes: 2 additions & 2 deletions Util.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.

import struct
from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from Crypto.Hash import MD2
from Crypto.Hash import MD4
from Crypto.Hash import MD5
Expand Down
10 changes: 5 additions & 5 deletions View.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.

import os
from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from PythonConsole import *

ViewTypes = []
Expand All @@ -29,9 +29,9 @@ def __init__(self, type, data):
self.data = data

class ViewFrame(QWidget):
statusUpdated = Signal(QWidget)
viewChanged = Signal(QWidget)
closeRequest = Signal(QWidget)
statusUpdated = pyqtSignal(QWidget)
viewChanged = pyqtSignal(QWidget)
closeRequest = pyqtSignal(QWidget)

def __init__(self, type, data, filename, viewList):
super(ViewFrame, self).__init__(None)
Expand Down
4 changes: 2 additions & 2 deletions binja.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
import stat
import thread
import Threads
from PySide.QtCore import *
from PySide.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from View import *
from BinaryData import *
from HexEditor import *
Expand Down
2 changes: 1 addition & 1 deletion readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Binary Ninja and the Binary Ninja logo are trademarks of Vector 35 LLC.
Binary Ninja is cross-platform and can run on Linux, Mac OS X, Windows, and FreeBSD. In order to run Binary Ninja, you will need to install a few prerequisites:

* [Python 2.7](https://www.python.org/downloads/)
* [PySide](https://pypi.python.org/pypi/PySide#installing-prerequisites) for Qt Python bindings
* [PyQt5](http://www.riverbankcomputing.com/software/pyqt/download5) for Qt Python bindings
* The [pycrypto](https://www.dlitz.net/software/pycrypto/) library

You can start Binary Ninja by running `binja.py` in the Python interpreter.
Expand Down