Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Working fix for #108 #173

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open

Commits on May 27, 2023

  1. Enable ReadWritePair for other platforms + Modify read

    I enabled ReadWritePair for other platforms that are not unix by removing any `#[cfg(unix)]`. I also updated TermRead to be an Iterator over Keys and not bytes. This gurantees a cross platform read of keys because they differ between wasm, unix and windows.
    FelixSelter committed May 27, 2023
    Configuration menu
    Copy the full SHA
    bef88b5 View commit details
    Browse the repository at this point in the history
  2. Moved various reading functions to TermTarget

    Its better to have only one place that checks if the TermTarget is a ReadWritePair instead of having them everywhere in the code. As the way input is read is determined by the TermTarget it made sense to move it there. I still need to implement the functionality for a ReadWritePairSource though
    FelixSelter committed May 27, 2023
    Configuration menu
    Copy the full SHA
    e6f393d View commit details
    Browse the repository at this point in the history
  3. Renamed fields of ReadWritePair and added utility function to convert…

    … Keys into utf8
    
    Renamed fields to clarify their new purpose.
    The utility function keys_to_utf8 will handle converting BackSpaces and Enter keys. Other functionality like arrow keys and delete may be implemented in the future
    FelixSelter committed May 27, 2023
    Configuration menu
    Copy the full SHA
    04bf2fc View commit details
    Browse the repository at this point in the history
  4. Added function to read a single key

    Maybe the errors need to be changed?
    io::ErrorKind::ResourceBusy requires to add the: #![feature(io_error_more)] attribute
    FelixSelter committed May 27, 2023
    Configuration menu
    Copy the full SHA
    d4c0e27 View commit details
    Browse the repository at this point in the history
  5. Added functionality to read utf8 into a buffer without exceeding its …

    …capacity and dropping long unicode chars
    
    This is required by the Read trait implementation
    FelixSelter committed May 27, 2023
    Configuration menu
    Copy the full SHA
    451c27d View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    596a142 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    9015353 View commit details
    Browse the repository at this point in the history