Skip to content

Commit

Permalink
[add] added missing translations
Browse files Browse the repository at this point in the history
[add] validator added to calculate price fields for mcl and usd line edits
  • Loading branch information
rumeysayilmaz committed Nov 8, 2021
1 parent 3dd08aa commit bba03fe
Show file tree
Hide file tree
Showing 5 changed files with 389 additions and 375 deletions.
6 changes: 5 additions & 1 deletion src/main/python/mainApp.py
Expand Up @@ -10,7 +10,7 @@
from datetime import datetime, timedelta
from qr_code_gen import Image
from PyQt5 import QtWidgets, QtCore, QtChart
from PyQt5.QtGui import QIcon, QRegExpValidator, QFont, QPainter
from PyQt5.QtGui import QIcon, QRegExpValidator, QFont, QPainter, QDoubleValidator
from PyQt5.QtChart import QChart, QChartView, QPieSeries
from PyQt5.QtCore import QThread, pyqtSlot, QDateTime, QSize, Qt, QTranslator, QRegExp
from PyQt5.QtWidgets import QMainWindow, QPushButton, QTableWidgetItem, QMessageBox, QDesktopWidget, QHeaderView, \
Expand Down Expand Up @@ -172,6 +172,10 @@ def __init__(self, parent=None):
# Market Page
self.exchange_market_request_button.clicked.connect(self.get_mcl_exchange_market)
self.exchange_market_request_button.setToolTip(self.tr("can be refreshed once in 20 seconds"))
self.regex_amount = QRegExp('[1-90_].+')
self.amount_validator = QRegExpValidator(self.regex_amount)
self.mcl_amount_lineEdit.setValidator(self.amount_validator)
self.usd_amount_lineEdit.setValidator(self.amount_validator)
self.mcl_amount_lineEdit.editingFinished.connect(self.calculate_usd_price)
self.usd_amount_lineEdit.editingFinished.connect(self.calculate_mcl_price)

Expand Down

0 comments on commit bba03fe

Please sign in to comment.