<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<font face="Georgia">An alternative to adding arguments to methods
would be an exception:<br>
</font><br>
<font face="Georgia"><font face="Georgia">-------------------------------------<br>
</font> "some event handling method"<br>
[<br>
"send message(s) to handle the event"<br>
] on: WhatEventTriggeredMe do: [ :ex |<br>
ex resume: event<br>
].<br>
-------------------------------------<br>
"and where the real work gets done"<br>
event _ WhatEventTriggeredMe signal.<br>
(event notNil and: [event shiftPressed]) ifTrue: [<br>
'behave differently"<br>
].<br>
</font><br>
<font face="Georgia"><font face="Georgia">-------------------------------------<br>
<br>
Cheers,<br>
Bob<br>
<br>
</font></font>
<div class="moz-cite-prefix">On 5/12/13 9:30 PM, David T. Lewis
wrote:<br>
</div>
<blockquote cite="mid:20130513013037.GA33940@shell.msen.com"
type="cite">
<pre wrap="">On Sun, May 12, 2013 at 05:52:32PM -0700, tim Rowledge wrote:
</pre>
<blockquote type="cite">
<pre wrap="">
On 12-05-2013, at 5:48 PM, "David T. Lewis" <a class="moz-txt-link-rfc2396E" href="mailto:lewis@mail.msen.com"><lewis@mail.msen.com></a> wrote:
</pre>
<blockquote type="cite">
<pre wrap="">
I also tried changing the menu selections to have separate selectors for
case-sensitive and non-case-sensitive versions of the search, and this
works fine. However, I'm not happy with that approach because it will
lead to a cluttered menu if we apply the approach consistently to the
various searches for "source with it", "comments with it", etc.
</pre>
</blockquote>
<pre wrap="">
Any reason not to go with
doFooblyCaseSensitive: evt shitPressed ?
</pre>
</blockquote>
<pre wrap="">
Yes, I think that is the right thing to do. So for example instead of having
"browseMethodsWithSourceString: aString" that checks Sensor shiftPressed, we
would have "browseMethodsWithSourceString: aString caseSensitive: caseSensitive".
That's what I did to try out the idea of separate menu selections for case-sensitive
and non-case-sensitive search, and it works fine.
It would be good to allow the shift state in the event to control the option.
Maybe that is easy to do, I just haven't actually tried it yet.
Dave
</pre>
</blockquote>
<br>
</body>
</html>