More work on transfer kitten
This commit is contained in:
@@ -405,7 +405,7 @@ class Send(Handler):
|
||||
self.cmd.styled('Permission granted for this transfer', fg='green')
|
||||
self.print()
|
||||
self.send_file_metadata()
|
||||
self.loop_tick()
|
||||
self.asyncio_loop.call_soon(self.loop_tick)
|
||||
|
||||
def start_transfer(self) -> None:
|
||||
if self.manager.active_file is None:
|
||||
|
||||
@@ -23,12 +23,16 @@ def safe_divide(numerator: Union[int, float], denominator: Union[int, float], ze
|
||||
|
||||
|
||||
def reduce_to_single_grapheme(text: str) -> str:
|
||||
limit = len(text)
|
||||
if limit < 2:
|
||||
return text
|
||||
x = 1
|
||||
while True:
|
||||
while x < limit:
|
||||
pos = truncate_point_for_length(text, x)
|
||||
if pos > 0:
|
||||
return text[:pos]
|
||||
pos += 1
|
||||
x += 1
|
||||
return text
|
||||
|
||||
|
||||
def render_path_in_width(path: str, width: int) -> str:
|
||||
|
||||
Reference in New Issue
Block a user