public inbox for cygwin-apps-cvs@sourceware.org
help / color / mirror / Atom feed
* [setup] branch master, updated. release_2.873-4-g8c34cc9
@ 2016-01-07 21:28 corinna
0 siblings, 0 replies; only message in thread
From: corinna @ 2016-01-07 21:28 UTC (permalink / raw)
To: cygwin-apps-cvs
https://sourceware.org/git/gitweb.cgi?p=cygwin-setup.git;h=8c34cc982b182a7e1d808668dfb572d7e3332170
commit 8c34cc982b182a7e1d808668dfb572d7e3332170
Author: Corinna Vinschen <corinna@vinschen.de>
Date: Thu Jan 7 22:28:03 2016 +0100
Fix logical expressions checking if buttons are checked
* AntiVirus.cc (AntiVirusPage::OnActivate): Fix logical expressions
checking if a button is checked.
* net.cc (NetPage::OnInit): Ditto.
* source.cc (SourcePage::OnActivate): Ditto.
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diff:
---
AntiVirus.cc | 14 +++++---------
net.cc | 11 ++++-------
source.cc | 15 ++++++---------
3 files changed, 15 insertions(+), 25 deletions(-)
diff --git a/AntiVirus.cc b/AntiVirus.cc
index 7dd01c4..876eb02 100644
--- a/AntiVirus.cc
+++ b/AntiVirus.cc
@@ -85,15 +85,11 @@ AntiVirusPage::OnActivate ()
{
load_dialog (GetHWND ());
// Check to see if any radio buttons are selected. If not, select a default.
- if ((!SendMessage
- (GetDlgItem (IDC_DISABLE_AV), BM_GETCHECK, 0,
- 0) == BST_CHECKED)
- && (!SendMessage (GetDlgItem (IDC_LEAVE_AV), BM_GETCHECK, 0, 0)
- == BST_CHECKED))
- {
- SendMessage (GetDlgItem (IDC_LEAVE_AV), BM_SETCHECK,
- BST_CHECKED, 0);
- }
+ if (SendMessage (GetDlgItem (IDC_DISABLE_AV), BM_GETCHECK, 0, 0)
+ != BST_CHECKED
+ && SendMessage (GetDlgItem (IDC_LEAVE_AV), BM_GETCHECK, 0, 0)
+ != BST_CHECKED)
+ SendMessage (GetDlgItem (IDC_LEAVE_AV), BM_SETCHECK, BST_CHECKED, 0);
}
bool
diff --git a/net.cc b/net.cc
index 1402c67..aa734da 100644
--- a/net.cc
+++ b/net.cc
@@ -135,13 +135,10 @@ NetPage::OnInit ()
CheckIfEnableNext();
// Check to see if any radio buttons are selected. If not, select a default.
- if ((!SendMessage (GetDlgItem (IDC_NET_IE5), BM_GETCHECK, 0, 0) ==
- BST_CHECKED)
- && (!SendMessage (GetDlgItem (IDC_NET_PROXY), BM_GETCHECK, 0, 0)
- == BST_CHECKED))
- {
- SendMessage (GetDlgItem (IDC_NET_DIRECT), BM_CLICK, 0, 0);
- }
+ if (SendMessage (GetDlgItem (IDC_NET_IE5), BM_GETCHECK, 0, 0) != BST_CHECKED
+ && SendMessage (GetDlgItem (IDC_NET_PROXY), BM_GETCHECK, 0, 0)
+ != BST_CHECKED)
+ SendMessage (GetDlgItem (IDC_NET_DIRECT), BM_CLICK, 0, 0);
}
long
diff --git a/source.cc b/source.cc
index 70751d2..90c98b5 100644
--- a/source.cc
+++ b/source.cc
@@ -103,15 +103,12 @@ SourcePage::OnActivate ()
load_dialog (GetHWND ());
// Check to see if any radio buttons are selected. If not, select a default.
- if ((!SendMessage
- (GetDlgItem (IDC_SOURCE_DOWNLOAD), BM_GETCHECK, 0,
- 0) == BST_CHECKED)
- && (!SendMessage (GetDlgItem (IDC_SOURCE_LOCALDIR), BM_GETCHECK, 0, 0)
- == BST_CHECKED))
- {
- SendMessage (GetDlgItem (IDC_SOURCE_NETINST), BM_SETCHECK,
- BST_CHECKED, 0);
- }
+ if (SendMessage (GetDlgItem (IDC_SOURCE_DOWNLOAD), BM_GETCHECK, 0, 0)
+ != BST_CHECKED
+ && SendMessage (GetDlgItem (IDC_SOURCE_LOCALDIR), BM_GETCHECK, 0, 0)
+ != BST_CHECKED)
+ SendMessage (GetDlgItem (IDC_SOURCE_NETINST), BM_SETCHECK,
+ BST_CHECKED, 0);
}
long
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2016-01-07 21:28 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-01-07 21:28 [setup] branch master, updated. release_2.873-4-g8c34cc9 corinna
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).