Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master'
Browse files Browse the repository at this point in the history
Conflicts:
	AUTHORS
	gui/qt/main_window.py
  • Loading branch information
pooler committed Nov 9, 2015
2 parents 2ab8b57 + 55fafc3 commit 2f56ac0
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 5 deletions.
1 change: 1 addition & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,5 @@ Genjix - Porting pro-mode functionality to lite-gui and worked on server
Slush - Work on the server. Designed the original Stratum spec.
Julian Toash (Tuxavant) - Various fixes to the client.
rdymac - Website and translations.
kyuupichan - Miscellaneous.
pooler - Litecoin port.
2 changes: 1 addition & 1 deletion gui/qt/amountedit.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def get_amount(self):

def setAmount(self, amount):
if amount is None:
self.setText("")
self.setText(" ") # Space forces repaint in case units changed
else:
self.setText(format_satoshis_plain(amount, self.decimal_point()))

Expand Down
3 changes: 1 addition & 2 deletions gui/qt/console.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,10 +213,9 @@ def write(self, text):
try:
# eval is generally considered bad practice. use it wisely!
result = eval(command, self.namespace, self.namespace)
result = util.json_encode(result)
if result != None:
if self.is_json:
util.print_msg(result)
util.print_msg(util.json_encode(result))
else:
self.appendPlainText(repr(result))
except SyntaxError:
Expand Down
6 changes: 4 additions & 2 deletions gui/qt/main_window.py
Original file line number Diff line number Diff line change
Expand Up @@ -2686,6 +2686,8 @@ def on_unit(x):
unit_result = units[unit_combo.currentIndex()]
if self.base_unit() == unit_result:
return
edits = self.amount_e, self.fee_e, self.receive_amount_e, fee_e
amounts = [edit.get_amount() for edit in edits]
if unit_result == 'LTC':
self.decimal_point = 8
elif unit_result == 'mLTC':
Expand All @@ -2698,8 +2700,8 @@ def on_unit(x):
self.history_list.update()
self.receive_list.update()
self.address_list.update()
self.do_clear()
fee_e.setAmount(self.wallet.fee_per_kb(self.config))
for edit, amount in zip(edits, amounts):
edit.setAmount(amount)
self.update_status()
unit_combo.currentIndexChanged.connect(on_unit)
gui_widgets.append((unit_label, unit_combo))
Expand Down

0 comments on commit 2f56ac0

Please sign in to comment.