Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
b6a9e1a692 | |||
d41ea8388f |
@ -393,12 +393,10 @@ class command:
|
||||
"""Check if text contains URLs that might cause false progress detection"""
|
||||
import re
|
||||
|
||||
# Common URL patterns that might contain progress-like patterns
|
||||
# Specific URL patterns - only match actual URLs, not filenames
|
||||
url_patterns = [
|
||||
r"https?://[^\s]+", # http:// or https:// URLs
|
||||
r"ftp://[^\s]+", # ftp:// URLs
|
||||
r"www\.[^\s]+", # www. domains
|
||||
r"[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}[/\w.-]*", # domain.com/path patterns
|
||||
r"\S+://\S+\.\S{2,}", # Any protocol:// with domain.ext
|
||||
r"www\.[^\s]+\.[a-zA-Z]{2,}", # www.domain.ext patterns
|
||||
]
|
||||
|
||||
for pattern in url_patterns:
|
||||
|
@ -4,6 +4,6 @@
|
||||
# Fenrir TTY screen reader
|
||||
# By Chrys, Storm Dragon, and contributors.
|
||||
|
||||
version = "2025.07.17"
|
||||
version = "2025.07.23"
|
||||
codeName = "testing"
|
||||
code_name = "testing"
|
||||
|
@ -561,6 +561,15 @@ class driver(inputDriver):
|
||||
# 0 = Numlock
|
||||
# 1 = Capslock
|
||||
# 2 = Rollen
|
||||
|
||||
# Use the first device with LED capability as authoritative source
|
||||
# to avoid inconsistent readings from multiple devices during initialization
|
||||
for fd, dev in self.iDevices.items():
|
||||
# Check if device has LED capability (capability 17)
|
||||
if 17 in dev.capabilities():
|
||||
return led in dev.leds()
|
||||
|
||||
# Fallback to old behavior if no device has LED capability
|
||||
for fd, dev in self.iDevices.items():
|
||||
if led in dev.leds():
|
||||
return True
|
||||
|
Reference in New Issue
Block a user