2626 print ('Could not import UI files, did you run contrib/generate-ui.sh' )
2727 exit (- 1 )
2828
29- from PySide2 .QtGui import QRegExpValidator
30- from PySide2 .QtWidgets import QApplication , QDialog , QDialogButtonBox , QFileDialog , QLineEdit , QMessageBox , QMainWindow , QMenu
31- from PySide2 .QtCore import QCoreApplication , QRegExp , Signal , Slot
29+ from PySide6 .QtGui import QRegularExpressionValidator
30+ from PySide6 .QtWidgets import QApplication , QDialog , QDialogButtonBox , QFileDialog , QLineEdit , QMessageBox , QMainWindow , QMenu
31+ from PySide6 .QtCore import QCoreApplication , QRegularExpression , Signal , Slot
3232
3333def do_command (f , * args , ** kwargs ):
3434 result = {}
@@ -59,7 +59,7 @@ def __init__(self, client, prompt_pin=True):
5959 self .setWindowTitle ('Send Pin' )
6060 self .client = client
6161 self .ui .pin_lineedit .setFocus ()
62- self .ui .pin_lineedit .setValidator (QRegExpValidator ( QRegExp ("[1-9]+" ), None ))
62+ self .ui .pin_lineedit .setValidator (QRegularExpressionValidator ( QRegularExpression ("[1-9]+" ), None ))
6363 self .ui .pin_lineedit .setEchoMode (QLineEdit .Password )
6464
6565 self .ui .p1_button .clicked .connect (self .button_clicked (1 ))
@@ -100,7 +100,7 @@ def __init__(self, client):
100100 self .setWindowTitle ('Get xpub' )
101101 self .client = client
102102
103- self .ui .path_lineedit .setValidator (QRegExpValidator ( QRegExp ("m(/[0-9]+['Hh]?)+" ), None ))
103+ self .ui .path_lineedit .setValidator (QRegularExpressionValidator ( QRegularExpression ("m(/[0-9]+['Hh]?)+" ), None ))
104104 self .ui .path_lineedit .setFocus ()
105105 self .ui .buttonBox .button (QDialogButtonBox .Close ).setAutoDefault (False )
106106
@@ -186,7 +186,7 @@ def __init__(self, client):
186186 self .setWindowTitle ('Sign Message' )
187187 self .client = client
188188
189- self .ui .path_lineedit .setValidator (QRegExpValidator ( QRegExp ("m(/[0-9]+['Hh]?)+" ), None ))
189+ self .ui .path_lineedit .setValidator (QRegularExpressionValidator ( QRegularExpression ("m(/[0-9]+['Hh]?)+" ), None ))
190190 self .ui .msg_textedit .setFocus ()
191191
192192 self .ui .signmsg_button .clicked .connect (self .signmsg_button_clicked )
@@ -207,7 +207,7 @@ def __init__(self, client):
207207 self .setWindowTitle ('Display Address' )
208208 self .client = client
209209
210- self .ui .path_lineedit .setValidator (QRegExpValidator ( QRegExp ("m(/[0-9]+['Hh]?)+" ), None ))
210+ self .ui .path_lineedit .setValidator (QRegularExpressionValidator ( QRegularExpression ("m(/[0-9]+['Hh]?)+" ), None ))
211211 self .ui .path_lineedit .setFocus ()
212212
213213 self .ui .go_button .clicked .connect (self .go_button_clicked )
@@ -239,7 +239,7 @@ def __init__(self, opts):
239239 self .ui .internal_checkbox .setChecked (opts ['internal' ])
240240 self .ui .keypool_checkbox .setChecked (opts ['keypool' ])
241241 self .ui .account_spinbox .setValue (opts ['account' ])
242- self .ui .path_lineedit .setValidator (QRegExpValidator ( QRegExp ("m(/[0-9]+['Hh]?)+/\*" ), None ))
242+ self .ui .path_lineedit .setValidator (QRegularExpressionValidator ( QRegularExpression ("m(/[0-9]+['Hh]?)+/\*" ), None ))
243243 if opts ['account_used' ]:
244244 self .ui .account_radio .setChecked (True )
245245 self .ui .path_radio .setChecked (False )
0 commit comments