Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nx-libs
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dimbor
nx-libs
Commits
838572f7
You need to sign in or sign up before continuing.
Commit
838572f7
authored
Oct 22, 2019
by
Ulrich Sibiller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Dialog.c: save some lines
parent
5067b169
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
33 deletions
+4
-33
Dialog.c
nx-X11/programs/Xserver/hw/nxagent/Dialog.c
+4
-33
No files found.
nx-X11/programs/Xserver/hw/nxagent/Dialog.c
View file @
838572f7
...
...
@@ -198,7 +198,6 @@ void nxagentLaunchDialog(DialogType dialogType)
type
=
DIALOG_KILL_SESSION_TYPE
;
local
=
DIALOG_KILL_SESSION_LOCAL
;
pid
=
&
nxagentKillDialogPid
;
break
;
}
case
DIALOG_SUSPEND_SESSION
:
...
...
@@ -207,7 +206,6 @@ void nxagentLaunchDialog(DialogType dialogType)
type
=
DIALOG_SUSPEND_SESSION_TYPE
;
local
=
DIALOG_SUSPEND_SESSION_LOCAL
;
pid
=
&
nxagentSuspendDialogPid
;
break
;
}
case
DIALOG_ROOTLESS
:
...
...
@@ -216,7 +214,6 @@ void nxagentLaunchDialog(DialogType dialogType)
type
=
DIALOG_ROOTLESS_TYPE
;
local
=
DIALOG_ROOTLESS_LOCAL
;
pid
=
&
nxagentRootlessDialogPid
;
break
;
}
case
DIALOG_PULLDOWN
:
...
...
@@ -226,7 +223,6 @@ void nxagentLaunchDialog(DialogType dialogType)
local
=
DIALOG_PULLDOWN_LOCAL
;
pid
=
&
nxagentPulldownDialogPid
;
window
=
nxagentPulldownWindow
;
break
;
}
case
DIALOG_FONT_REPLACEMENT
:
...
...
@@ -235,7 +231,6 @@ void nxagentLaunchDialog(DialogType dialogType)
type
=
DIALOG_FONT_REPLACEMENT_TYPE
;
local
=
DIALOG_FONT_REPLACEMENT_LOCAL
;
pid
=
&
nxagentFontsReplacementDialogPid
;
break
;
}
case
DIALOG_FAILED_RECONNECTION
:
...
...
@@ -244,7 +239,6 @@ void nxagentLaunchDialog(DialogType dialogType)
type
=
DIALOG_FAILED_RECONNECTION_TYPE
;
local
=
DIALOG_FAILED_RECONNECTION_LOCAL
;
pid
=
&
nxagentFailedReconnectionDialogPid
;
break
;
}
case
DIALOG_ENABLE_DESKTOP_RESIZE_MODE
:
...
...
@@ -253,7 +247,6 @@ void nxagentLaunchDialog(DialogType dialogType)
type
=
DIALOG_ENABLE_DESKTOP_RESIZE_MODE_TYPE
;
local
=
DIALOG_ENABLE_DESKTOP_RESIZE_MODE_LOCAL
;
pid
=
&
nxagentEnableRandRModeDialogPid
;
break
;
}
case
DIALOG_DISABLE_DESKTOP_RESIZE_MODE
:
...
...
@@ -262,7 +255,6 @@ void nxagentLaunchDialog(DialogType dialogType)
type
=
DIALOG_DISABLE_DESKTOP_RESIZE_MODE_TYPE
;
local
=
DIALOG_DISABLE_DESKTOP_RESIZE_MODE_LOCAL
;
pid
=
&
nxagentDisableRandRModeDialogPid
;
break
;
}
case
DIALOG_ENABLE_DEFER_MODE
:
...
...
@@ -271,7 +263,6 @@ void nxagentLaunchDialog(DialogType dialogType)
type
=
DIALOG_ENABLE_DEFER_MODE_TYPE
;
local
=
DIALOG_ENABLE_DEFER_MODE_LOCAL
;
pid
=
&
nxagentEnableDeferModePid
;
break
;
}
case
DIALOG_DISABLE_DEFER_MODE
:
...
...
@@ -280,7 +271,6 @@ void nxagentLaunchDialog(DialogType dialogType)
type
=
DIALOG_DISABLE_DEFER_MODE_TYPE
;
local
=
DIALOG_DISABLE_DEFER_MODE_LOCAL
;
pid
=
&
nxagentDisableDeferModePid
;
break
;
}
case
DIALOG_ENABLE_AUTOGRAB_MODE
:
...
...
@@ -289,7 +279,6 @@ void nxagentLaunchDialog(DialogType dialogType)
type
=
DIALOG_ENABLE_AUTOGRAB_MODE_TYPE
;
local
=
DIALOG_ENABLE_AUTOGRAB_MODE_LOCAL
;
pid
=
&
nxagentEnableAutograbModePid
;
break
;
}
case
DIALOG_DISABLE_AUTOGRAB_MODE
:
...
...
@@ -298,7 +287,6 @@ void nxagentLaunchDialog(DialogType dialogType)
type
=
DIALOG_DISABLE_AUTOGRAB_MODE_TYPE
;
local
=
DIALOG_DISABLE_AUTOGRAB_MODE_LOCAL
;
pid
=
&
nxagentDisableAutograbModePid
;
break
;
}
default:
...
...
@@ -325,8 +313,7 @@ void nxagentLaunchDialog(DialogType dialogType)
}
/*
* We don't want to receive SIGCHLD
* before we store the child pid.
* We don't want to receive SIGCHLD before we store the child pid.
*/
sigemptyset
(
&
set
);
...
...
@@ -346,8 +333,7 @@ void nxagentLaunchDialog(DialogType dialogType)
dialogDisplay
[
0
]
=
'\0'
;
/*
* Restore the previous set of
* blocked signal.
* Restore the previous set of blocked signal.
*/
sigprocmask
(
SIG_SETMASK
,
&
oldSet
,
NULL
);
...
...
@@ -385,8 +371,7 @@ void nxagentFailedReconnectionDialog(int alert, char *error)
NXTransAlert
(
alert
,
NX_ALERT_REMOTE
);
/*
* Make it possible to interrupt the
* loop with a signal.
* Make it possible to interrupt the loop with a signal.
*/
while
(
NXDisplayError
(
nxagentDisplay
)
==
0
&&
...
...
@@ -477,73 +462,61 @@ void nxagentTerminateDialog(DialogType type)
case
DIALOG_KILL_SESSION
:
{
pid
=
nxagentKillDialogPid
;
break
;
}
case
DIALOG_SUSPEND_SESSION
:
{
pid
=
nxagentSuspendDialogPid
;
break
;
}
case
DIALOG_ROOTLESS
:
{
pid
=
nxagentRootlessDialogPid
;
break
;
}
case
DIALOG_PULLDOWN
:
{
pid
=
nxagentPulldownDialogPid
;
break
;
}
case
DIALOG_FONT_REPLACEMENT
:
{
pid
=
nxagentFontsReplacementDialogPid
;
break
;
}
case
DIALOG_FAILED_RECONNECTION
:
{
pid
=
nxagentFailedReconnectionDialogPid
;
break
;
}
case
DIALOG_ENABLE_DESKTOP_RESIZE_MODE
:
{
pid
=
nxagentEnableRandRModeDialogPid
;
break
;
}
case
DIALOG_DISABLE_DESKTOP_RESIZE_MODE
:
{
pid
=
nxagentDisableRandRModeDialogPid
;
break
;
}
case
DIALOG_ENABLE_DEFER_MODE
:
{
pid
=
nxagentEnableDeferModePid
;
break
;
}
case
DIALOG_DISABLE_DEFER_MODE
:
{
pid
=
nxagentDisableDeferModePid
;
break
;
}
case
DIALOG_ENABLE_AUTOGRAB_MODE
:
{
pid
=
nxagentEnableAutograbModePid
;
break
;
}
case
DIALOG_DISABLE_AUTOGRAB_MODE
:
{
pid
=
nxagentDisableAutograbModePid
;
break
;
}
default:
...
...
@@ -577,13 +550,11 @@ void nxagentTerminateDialog(DialogType type)
void
nxagentTerminateDialogs
(
void
)
{
DialogType
type
;
#ifdef DEBUG
fprintf
(
stderr
,
"nxagentTerminateDialogs: Terminating all the running dialogs.
\n
"
);
#endif
for
(
type
=
DIALOG_FIRST_TAG
;
type
<
DIALOG_LAST_TAG
;
type
++
)
for
(
DialogType
type
=
DIALOG_FIRST_TAG
;
type
<
DIALOG_LAST_TAG
;
type
++
)
{
nxagentTerminateDialog
(
type
);
}
...
...
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