Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
L
luna
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ops
luna
Commits
6d8c33da
Commit
6d8c33da
authored
May 23, 2018
by
ibuler
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Update] 更新初始terminal大小
parent
af5e0b44
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
6 deletions
+3
-6
ssh-term.component.ts
src/app/elements/ssh-term/ssh-term.component.ts
+3
-6
No files found.
src/app/elements/ssh-term/ssh-term.component.ts
View file @
6d8c33da
...
...
@@ -4,7 +4,6 @@ import {NavList} from '../../pages/control/control/control.component';
import
{
UUIDService
}
from
'../../app.service'
;
import
{
CookieService
}
from
'ngx-cookie-service'
;
import
{
TermWS
}
from
'../../globals'
;
import
{
isNumber
}
from
'ngx-bootstrap/timepicker/timepicker.utils'
;
const
ws
=
TermWS
;
...
...
@@ -35,11 +34,9 @@ export class ElementSshTermComponent implements OnInit, AfterViewInit {
background
:
'#1f1b1b'
}
});
const
rowInit
=
this
.
_cookie
.
get
(
'rows'
)
||
'24'
;
const
colsInit
=
this
.
_cookie
.
get
(
'cols'
)
||
'80'
;
if
(
isNumber
(
rowInit
)
&&
isNumber
(
colsInit
))
{
this
.
term
.
resize
(
parseInt
(
colsInit
,
10
),
parseInt
(
rowInit
,
10
));
}
const
rowInit
=
parseInt
(
this
.
_cookie
.
get
(
'rows'
)
||
'24'
,
10
);
const
colsInit
=
parseInt
(
this
.
_cookie
.
get
(
'cols'
)
||
'80'
,
10
);
this
.
term
.
resize
(
colsInit
,
rowInit
);
}
ngAfterViewInit
()
{
...
...
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