support osc 52 clipboard copy integration.
This feature is particularly relevant for mosh for chrome (which also used in windows I believe).
This commit is contained in:
@@ -42,6 +42,8 @@
|
||||
|
||||
using namespace Terminal;
|
||||
|
||||
static const size_t MAXIMUM_CLIPBOARD_SIZE = 16*1024;
|
||||
|
||||
Dispatcher::Dispatcher()
|
||||
: params(), parsed_params(), parsed( false ), dispatch_chars(),
|
||||
OSC_string(), terminal_to_host()
|
||||
@@ -235,7 +237,7 @@ void Dispatcher::dispatch( Function_Type type, const Parser::Action *act, Frameb
|
||||
void Dispatcher::OSC_put( const Parser::OSC_Put *act )
|
||||
{
|
||||
assert( act->char_present );
|
||||
if ( OSC_string.size() < 256 ) { /* should be a long enough window title */
|
||||
if ( OSC_string.size() < MAXIMUM_CLIPBOARD_SIZE) {
|
||||
OSC_string.push_back( act->ch );
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user