Re: [code] Improved File Browser

From: Alexander Misel <alexander_misel.att.live.cn>
Date: Fri, 12 Oct 2018 02:46:54 +0000

It works but the operation gives a flash of the new buffer then switch back. I hope this could be done internally or just before the view that a buffer will use is chosen.
________________________________
From: Mitchell <m.att.foicica.com>
Sent: Thursday, October 11, 2018 20:39
To: code.att.foicica.com
Subject: Re: [code] Improved File Browser

Hi Alexander,

On Thu, 11 Oct 2018, Alexander Misel wrote:

> Now I am looking forward to a feature that locks a view to only have ONE buffer (i.e. File Browser, TODO list). Any sugguestions on how to implement it?

One idea I had was to connect to `events.BUFFER_AFTER_SWITCH` and check to see if the current view (`view`) contains a buffer it shouldn't. If so, immediately call `view:goto_buffer(...)` with the buffer you want to "lock". I'm not certain this will work. It's just an idea.

Cheers,
Mitchell

--
You are subscribed to code.att.foicica.com.
To change subscription settings, send an e-mail to code+help.att.foicica.com.
To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.
-- 
You are subscribed to code.att.foicica.com.
To change subscription settings, send an e-mail to code+help.att.foicica.com.
To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.
Received on Thu 11 Oct 2018 - 22:46:54 EDT

This archive was generated by hypermail 2.2.0 : Fri 12 Oct 2018 - 06:40:50 EDT