diff options
-rw-r--r-- | mouse.py | 10 | ||||
-rw-r--r-- | xf86config.py | 2 |
2 files changed, 10 insertions, 2 deletions
@@ -73,11 +73,17 @@ class Mouse (SimpleConfigFile): } # XXX fixme - externalize - def __init__ (self): + def __init__ (self, skipProbe = 0): self.info = {} self.device = None self.emulate = 0 self.set ("Generic - 3 Button Mouse (PS/2)") + self.wasProbed = 0 + if not skipProbe: + self.probe() + + def probed(self): + return self.wasProbed def probe (self): list = kudzu.probe(kudzu.CLASS_MOUSE, kudzu.BUS_UNSPEC, @@ -108,9 +114,11 @@ class Mouse (SimpleConfigFile): self.set("Generic - 2 Button Mouse (serial)", 1) self.device = device + self.wasProbed = 1 return 1 else: self.set("None - None") + self.wasProbed = 0 return 0 def available (self): diff --git a/xf86config.py b/xf86config.py index d9a60c5eb..acd2855c4 100644 --- a/xf86config.py +++ b/xf86config.py @@ -535,7 +535,7 @@ class XF86Config: if mouse: self.setMouse(mouse) else: - self.mouse = Mouse () + self.mouse = Mouse (skipProbe = 1) self.server = None self.vidCards = [] self.cardMan = None |