git.cweiske.de
/
enigma2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add missing positions for < > key
[enigma2.git]
/
lib
/
python
/
Components
/
Input.py
diff --git
a/lib/python/Components/Input.py
b/lib/python/Components/Input.py
index f1a17d90b8f042453d18418a4c9ff9af4b648506..0bd13059e3ad69d75bcb7dbb4a0ce26afcab7309 100644
(file)
--- a/
lib/python/Components/Input.py
+++ b/
lib/python/Components/Input.py
@@
-6,7
+6,7
@@
from enigma import eLabel
from Tools.NumericalTextInput import NumericalTextInput
from Tools.NumericalTextInput import NumericalTextInput
-class Input(
HTMLComponent, GUIComponent, VariableTex
t):
+class Input(
VariableText, HTMLComponent, GUIComponen
t):
TEXT = 0
PIN = 1
NUMBER = 2
TEXT = 0
PIN = 1
NUMBER = 2
@@
-54,7
+54,7
@@
class Input(HTMLComponent, GUIComponent, VariableText):
self.update()
def up(self):
self.update()
def up(self):
- if self.text[self.currPos] == "9":
+ if self.text[self.currPos] == "9"
or self.text[self.currPos] == " "
:
newNumber = "0"
else:
newNumber = str(int(self.text[self.currPos]) + 1)
newNumber = "0"
else:
newNumber = str(int(self.text[self.currPos]) + 1)
@@
-62,13
+62,18
@@
class Input(HTMLComponent, GUIComponent, VariableText):
self.update()
def down(self):
self.update()
def down(self):
- if self.text[self.currPos] == "0":
+ if self.text[self.currPos] == "0"
or self.text[self.currPos] == " "
:
newNumber = "9"
else:
newNumber = str(int(self.text[self.currPos]) - 1)
newNumber = "9"
else:
newNumber = str(int(self.text[self.currPos]) - 1)
+
self.text = self.text[0:self.currPos] + newNumber + self.text[self.currPos + 1:]
self.update()
self.text = self.text[0:self.currPos] + newNumber + self.text[self.currPos + 1:]
self.update()
+ def delete(self):
+ self.text = self.text[:self.currPos] + self.text[self.currPos + 1:]
+ self.update()
+
def number(self, number):
if self.type == self.TEXT:
newChar = self.numericalTextInput.getKey(number)
def number(self, number):
if self.type == self.TEXT:
newChar = self.numericalTextInput.getKey(number)