[perl #108470] Make Term::ReadLine use AE if available
authorDarin McBride <dmcbride@cpan.org>
Mon, 30 Jan 2012 04:45:44 +0000 (20:45 -0800)
committerFather Chrysostomos <sprout@cpan.org>
Mon, 30 Jan 2012 05:53:50 +0000 (21:53 -0800)
commitb60dd40238e682dc3d405c6f6d0e42572cca27f2
treed45f9a86eebaf4608ff1973513fe93c096e892dc
parent8dcc3739b1b464070001663b48ec4983f18a178b
[perl #108470] Make Term::ReadLine use AE if available

Term::ReadLine only allows the Tk event loop to be called during
a readline call. This should be updated to use AnyEvent which will
still work with Tk, as well as any other event loop the user may need.

With this patch, T::RL now uses AnyEvent if it is loaded, falling back
to Tk otherwise; so the Tk mode won't be affected.

T::RL::Stub has its own get_line. This does not honour the tkRunning
flag at all. If I remove it, it's fine. This patch does so.
dist/Term-ReadLine/lib/Term/ReadLine.pm
dist/Term-ReadLine/t/AE.t [new file with mode: 0644]
dist/Term-ReadLine/t/AETk.t [new file with mode: 0644]
dist/Term-ReadLine/t/Tk.t [new file with mode: 0644]