Skip to content

Commit

Permalink
remove double def as same result
Browse files Browse the repository at this point in the history
convert return as move to move (x, y)
  • Loading branch information
Furtif committed Jun 11, 2023
1 parent 2b70924 commit 52e22ba
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 10 deletions.
5 changes: 3 additions & 2 deletions displaymod.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,14 +196,15 @@ def initJson(self, jsdata):
self.jsondata = jsdata

def resize(self, x, y):
super(screenWidget, self).resize(x, y)
super(screenWidget, self).resize(int(x), int(y))
self.update_json()

def lock(self, lock):
pass

def move(self, x, y):
return
super(screenWidget, self).move(int(x), int(y))
self.update_json()

def update_json(self):
if self.jsondata:
Expand Down
9 changes: 1 addition & 8 deletions elm.py
Original file line number Diff line number Diff line change
Expand Up @@ -516,13 +516,6 @@ def check_elm(self):
return False


def get_can_addr(txa):
for d in dnat.keys():
if dnat[d] == txa:
return d
return None


class ELM:
'''ELM327 class'''

Expand Down Expand Up @@ -1261,7 +1254,7 @@ def set_can_addr(self, addr, ecu, canline=0):
if 'idTx' in ecu and 'idRx' in ecu:
TXa = ecu['idTx']
RXa = ecu['idRx']
self.currentaddress = elm.get_can_addr(TXa)
self.currentaddress = get_can_addr(TXa)
else:
TXa = dnat[addr]
RXa = snat[addr]
Expand Down

0 comments on commit 52e22ba

Please sign in to comment.