Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit f1177b4

Browse files
author
slavanorm
committed
hack limitations
1 parent 775dd2e commit f1177b4

File tree

8 files changed

+3
-16
lines changed

8 files changed

+3
-16
lines changed

.DS_Store

6 KB
Binary file not shown.

lua/.DS_Store

6 KB
Binary file not shown.

lua/leetcode-ui/question.lua

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,6 @@ function Question:create_buffer()
8989
vim.cmd("$tabe " .. path)
9090
self.bufnr = vim.api.nvim_get_current_buf()
9191
self.winid = vim.api.nvim_get_current_win()
92-
ui_utils.win_set_winfixbuf(self.winid)
9392

9493
self:open_buffer(existed)
9594
end

lua/leetcode-ui/renderer/menu.lua

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -146,9 +146,6 @@ function Menu:apply_options()
146146
spell = false,
147147
signcolumn = "no",
148148
})
149-
vim.schedule(function()
150-
ui_utils.win_set_winfixbuf(self.winid)
151-
end)
152149
end
153150

154151
function Menu:unmount()

lua/leetcode-ui/split/description.lua

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,6 @@ function Description:mount()
5858
signcolumn = "no",
5959
linebreak = true,
6060
})
61-
ui_utils.win_set_winfixbuf(self.winid)
62-
6361
if not img_ok and config.user.image_support then
6462
log.error("image.nvim not found but `image_support` is enabled")
6563
end

lua/leetcode-ui/utils.lua

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -130,14 +130,6 @@ function utils.win_set_opts(winid, options)
130130
end
131131
end
132132

133-
---@param winid number
134-
function utils.win_set_winfixbuf(winid)
135-
local u = require("leetcode.utils")
136-
u.with_version("0.10.0", function()
137-
utils.win_set_opts(winid, { winfixbuf = true })
138-
end)
139-
end
140-
141133
---@param winid number
142134
---@param bufnr number
143135
---@param force? boolean

lua/leetcode.lua

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,9 @@ local function log_buf_not_empty(bufname)
1919
end
2020

2121
local function buf_is_empty(buf)
22-
local lines = vim.api.nvim_buf_get_lines(buf, 0, -1, true)
23-
return not (#lines > 1 or (#lines == 1 and lines[1]:len() > 0))
22+
return true
23+
--local lines = vim.api.nvim_buf_get_lines(buf, 0, -1, true)
24+
--return not (#lines > 1 or (#lines == 1 and lines[1]:len() > 0))
2425
end
2526

2627
---@param on_vimenter boolean

lua/leetcode/.DS_Store

6 KB
Binary file not shown.

0 commit comments

Comments
 (0)