mirror of https://gitlab.com/basile.b/dexed.git
fix, tab captions note update when closing doc from shortcut
This commit is contained in:
parent
8503a81b16
commit
3b46ffb013
|
@ -1,3 +1,9 @@
|
|||
# v3.9.10-dev
|
||||
|
||||
## Bugs fixed
|
||||
|
||||
- Editor tabs: caption not updated when split page is closed using the File menu or the shortcut.
|
||||
|
||||
# v3.9.9
|
||||
|
||||
## Enhancement
|
||||
|
|
|
@ -291,7 +291,7 @@ begin
|
|||
with result do
|
||||
case index of
|
||||
0: begin identifier := 'Select next page'; shortcut:= fNextPage; end;
|
||||
1: begin identifier := 'Select previous page'; shortcut:= fPrevPage; end;
|
||||
1: begin identifier := 'Select previous page'; shortcut:= fPrevPage; end;
|
||||
2: begin identifier := 'Move page left'; shortcut:= fMoveLeft; end;
|
||||
3: begin identifier := 'Move page right'; shortcut:= fMoveRight; end;
|
||||
else raise Exception.CreateFmt(
|
||||
|
@ -502,6 +502,8 @@ begin
|
|||
end;
|
||||
|
||||
procedure TEditorWidget.docClosing(document: TDexedMemo);
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
if document.isNotAssigned then
|
||||
exit;
|
||||
|
@ -509,6 +511,8 @@ begin
|
|||
if document = fDoc then
|
||||
fDoc := nil;
|
||||
pageControl.deletePage(pageControl.pageIndex);
|
||||
for i:= 0 to pageControl.pageCount-1 do
|
||||
updatePageCaption(pageControl.pages[i]);
|
||||
updateImperative;
|
||||
end;
|
||||
|
||||
|
@ -813,7 +817,7 @@ procedure TEditorWidget.updateStatusBar;
|
|||
const
|
||||
modstr: array[boolean] of string = ('...', 'MODIFIED');
|
||||
begin
|
||||
if fDoc = nil then
|
||||
if fDoc.isNotAssigned then
|
||||
begin
|
||||
editorStatus.Panels[0].Text := '';
|
||||
editorStatus.Panels[1].Text := '';
|
||||
|
@ -867,8 +871,7 @@ procedure TEditorWidget.PageControlButtonClick(sender: TObject; button: TPageCon
|
|||
var
|
||||
i: integer;
|
||||
begin
|
||||
if ((button = pbClose) and (pageControl.currentPage = pageControl.splitPage))
|
||||
or (button = pbSplit) then
|
||||
if (button = pbClose) or (button = pbSplit) then
|
||||
begin
|
||||
for i:= 0 to pageControl.pageCount-1 do
|
||||
updatePageCaption(pageControl.pages[i]);
|
||||
|
@ -884,7 +887,7 @@ end;
|
|||
|
||||
procedure TEditorWidget.updateDelayed;
|
||||
begin
|
||||
if fDoc = nil then
|
||||
if fDoc.isNotAssigned then
|
||||
exit;
|
||||
updateStatusBar;
|
||||
if not fKeyChanged then
|
||||
|
|
Loading…
Reference in New Issue