aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/programs/Xserver/hw/nxagent
diff options
context:
space:
mode:
authorUlrich Sibiller <uli42@gmx.de>2019-12-17 22:56:44 +0100
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2020-01-05 23:36:02 +0100
commit30fb45b2a65aa8cf1a544339b1288119319de455 (patch)
tree9f7decd9b6ebc4d922648ae4bb8633398b57d256 /nx-X11/programs/Xserver/hw/nxagent
parentd634f26bb54dea56830b16bdc7f555c08f59dc03 (diff)
downloadnx-libs-30fb45b2a65aa8cf1a544339b1288119319de455.tar.gz
nx-libs-30fb45b2a65aa8cf1a544339b1288119319de455.tar.bz2
nx-libs-30fb45b2a65aa8cf1a544339b1288119319de455.zip
Clipboard.c: cleanup parentheses
Diffstat (limited to 'nx-X11/programs/Xserver/hw/nxagent')
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Clipboard.c32
1 files changed, 17 insertions, 15 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c
index adc02a17c..47eaa946d 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c
@@ -610,8 +610,8 @@ void nxagentClearClipboard(ClientPtr pClient, WindowPtr pWindow)
int nxagentFindLastSelectionOwnerIndex(XlibAtom sel)
{
int i = 0;
- while ((i < nxagentMaxSelections) &&
- (lastSelectionOwner[i].selection != sel))
+ while (i < nxagentMaxSelections &&
+ lastSelectionOwner[i].selection != sel)
{
i++;
}
@@ -625,8 +625,8 @@ int nxagentFindLastSelectionOwnerIndex(XlibAtom sel)
int nxagentFindCurrentSelectionIndex(Atom sel)
{
int i = 0;
- while ((i < NumCurrentSelections) &&
- (CurrentSelections[i].selection != sel))
+ while (i < NumCurrentSelections &&
+ CurrentSelections[i].selection != sel)
{
i++;
}
@@ -1328,7 +1328,8 @@ void nxagentHandleSelectionNotifyFromXServer(XEvent *X)
* the real X server). We now need to transfer it to the original
* requestor, which is stored in the lastClient* variables.
*/
- if ((lastClientStage == SelectionStageNone) && (X->xselection.property == serverTransToAgentProperty))
+ if (lastClientStage == SelectionStageNone &&
+ X->xselection.property == serverTransToAgentProperty)
{
#ifdef DEBUG
fprintf(stderr, "%s: Starting selection transferral for client [%d].\n", __func__,
@@ -1568,10 +1569,10 @@ void nxagentSetSelectionCallback(CallbackListPtr *callbacks, void *data,
fprintf(stderr, "%s: pCurSel->selection [%s]\n", __func__, NameForAtom(pCurSel->selection));
#endif
- if ((pCurSel->pWin != NULL) &&
- (nxagentOption(Clipboard) != ClipboardNone) && /* FIXME: shouldn't we also check for != ClipboardClient? */
- ((pCurSel->selection == XA_PRIMARY) ||
- (pCurSel->selection == clientCLIPBOARD)))
+ if (pCurSel->pWin != NULL &&
+ nxagentOption(Clipboard) != ClipboardNone && /* FIXME: shouldn't we also check for != ClipboardClient? */
+ (pCurSel->selection == XA_PRIMARY ||
+ pCurSel->selection == clientCLIPBOARD))
{
#ifdef DEBUG
fprintf(stderr, "%s: calling nxagentSetSelectionOwner\n", __func__);
@@ -1897,10 +1898,10 @@ int nxagentConvertSelection(ClientPtr client, WindowPtr pWin, Atom selection,
}
#endif
- if ((target == clientTEXT) ||
- (target == XA_STRING) ||
- (target == clientCOMPOUND_TEXT) ||
- (target == clientUTF8_STRING))
+ if (target == clientTEXT ||
+ target == XA_STRING ||
+ target == clientCOMPOUND_TEXT ||
+ target == clientUTF8_STRING)
{
lastClientWindowPtr = pWin;
SetClientSelectionStage(None);
@@ -2109,8 +2110,9 @@ int nxagentSendNotify(xEvent *event)
WindowPtr nxagentGetClipboardWindow(Atom property)
{
int i = nxagentFindLastSelectionOwnerIndex(nxagentLastRequestedSelection);
- if ((i < nxagentMaxSelections) && (property == clientCutProperty) &&
- (lastSelectionOwner[i].windowPtr != NULL))
+ if (i < nxagentMaxSelections &&
+ property == clientCutProperty &&
+ lastSelectionOwner[i].windowPtr != NULL)
{
#ifdef DEBUG
fprintf(stderr, "%s: Returning last [%d] selection owner window [%p] (0x%x).\n", __func__,