Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
poezio
poezio
Commits
968ed665
Commit
968ed665
authored
Jul 07, 2016
by
mathieui
Browse files
Fix the configure and bookmark tab
parent
dae64141
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
6 deletions
+8
-6
poezio/windows/bookmark_forms.py
poezio/windows/bookmark_forms.py
+4
-3
poezio/windows/data_forms.py
poezio/windows/data_forms.py
+4
-3
No files found.
poezio/windows/bookmark_forms.py
View file @
968ed665
...
...
@@ -3,7 +3,8 @@ Windows used inthe bookmarkstab
"""
import
curses
from
poezio.windows.base_wins
import
Win
,
TAB_WIN
from
poezio.windows
import
base_wins
from
poezio.windows.base_wins
import
Win
from
poezio.windows.inputs
import
Input
from
poezio.windows.data_forms
import
FieldInput
from
poezio.theming
import
to_curses_attr
,
get_theme
...
...
@@ -130,7 +131,7 @@ class BookmarkAutojoinWin(FieldInput, Win):
class
BookmarksWin
(
Win
):
def
__init__
(
self
,
bookmarks
,
height
,
width
,
y
,
x
):
self
.
_win
=
TAB_WIN
.
derwin
(
height
,
width
,
y
,
x
)
self
.
_win
=
base_wins
.
TAB_WIN
.
derwin
(
height
,
width
,
y
,
x
)
self
.
scroll_pos
=
0
self
.
_current_input
=
0
self
.
current_horizontal_input
=
0
...
...
@@ -181,7 +182,7 @@ class BookmarksWin(Win):
def
resize
(
self
,
height
,
width
,
y
,
x
):
self
.
height
=
height
self
.
width
=
width
self
.
_win
=
TAB_WIN
.
derwin
(
height
,
width
,
y
,
x
)
self
.
_win
=
base_wins
.
TAB_WIN
.
derwin
(
height
,
width
,
y
,
x
)
# Adjust the scroll position, if resizing made the window too small
# for the cursor to be visible
while
self
.
current_input
-
self
.
scroll_pos
>
self
.
height
-
1
:
...
...
poezio/windows/data_forms.py
View file @
968ed665
...
...
@@ -6,7 +6,8 @@ does not inherit from the Win base class), as it will create the
others when needed.
"""
from
poezio.windows.base_wins
import
Win
,
TAB_WIN
from
poezio.windows
import
base_wins
from
poezio.windows.base_wins
import
Win
from
poezio.windows.inputs
import
Input
from
poezio.theming
import
to_curses_attr
,
get_theme
...
...
@@ -341,7 +342,7 @@ class FormWin(object):
}
def
__init__
(
self
,
form
,
height
,
width
,
y
,
x
):
self
.
_form
=
form
self
.
_win
=
TAB_WIN
.
derwin
(
height
,
width
,
y
,
x
)
self
.
_win
=
base_wins
.
TAB_WIN
.
derwin
(
height
,
width
,
y
,
x
)
self
.
scroll_pos
=
0
self
.
current_input
=
0
self
.
inputs
=
[]
# dict list
...
...
@@ -364,7 +365,7 @@ class FormWin(object):
def
resize
(
self
,
height
,
width
,
y
,
x
):
self
.
height
=
height
self
.
width
=
width
self
.
_win
=
TAB_WIN
.
derwin
(
height
,
width
,
y
,
x
)
self
.
_win
=
base_wins
.
TAB_WIN
.
derwin
(
height
,
width
,
y
,
x
)
# Adjust the scroll position, if resizing made the window too small
# for the cursor to be visible
while
self
.
current_input
-
self
.
scroll_pos
>
self
.
height
-
1
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment