<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; AHK : двойной клик и около.]]></title>
	<link rel="self" href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=7740&amp;type=atom" />
	<updated>2012-10-30T14:36:31Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=7740</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65262#p65262" />
			<content type="html"><![CDATA[<p>Да, там я его нашёл, но как не силился, как не переводил, не понял почти ничего.&nbsp; <img src="//forum.script-coding.com/img/smilies/sad.png" width="15" height="15" /></p><br /><p>Что касается скрипта - всё работает прекрасно. Что-то я сегодня не внимательный. <img src="//forum.script-coding.com/img/smilies/sad.png" width="15" height="15" /></p>]]></content>
			<author>
				<name><![CDATA[Pokerist]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24990</uri>
			</author>
			<updated>2012-10-30T14:36:31Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65262#p65262</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65255#p65255" />
			<content type="html"><![CDATA[<div class="quotebox"><blockquote><p>Про &quot;#if&quot; вообще ничего нигде нет.</p></blockquote></div><p><a href="http://l.autohotkey.net/docs/commands/_If.htm">http://l.autohotkey.net/docs/commands/_If.htm</a></p>]]></content>
			<author>
				<name><![CDATA[Malcev]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26930</uri>
			</author>
			<updated>2012-10-30T13:30:08Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65255#p65255</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65254#p65254" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>Malcev пишет:</cite><blockquote><p>Да. Пропустил <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /></p></blockquote></div><p>Спасибо!</p>]]></content>
			<author>
				<name><![CDATA[Pokerist]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24990</uri>
			</author>
			<updated>2012-10-30T13:27:43Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65254#p65254</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65253#p65253" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>creature.ws пишет:</cite><blockquote><p>«Непонятно» не принимается.</p></blockquote></div><p>Разобрался, спасибо! Просто с фукциями, а также такими встроенными переменными и &quot;#if&quot; не имел дела до этого. </p><p>Про &quot;#if&quot; вообще ничего нигде нет. Только по аналогии с &quot;#IfWinActive&quot; смог догадаться что тут к чему. Кстати их даже в списке команд <a href="http://www.script-coding.com/AutoHotkey/CommandList.html">http://www.script-coding.com/AutoHotkey … dList.html</a> нет. <img src="//forum.script-coding.com/img/smilies/hmm.png" width="15" height="15" /></p>]]></content>
			<author>
				<name><![CDATA[Pokerist]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24990</uri>
			</author>
			<updated>2012-10-30T13:25:01Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65253#p65253</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65252#p65252" />
			<content type="html"><![CDATA[<p>Да. Пропустил <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /></p>]]></content>
			<author>
				<name><![CDATA[Malcev]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26930</uri>
			</author>
			<updated>2012-10-30T13:24:36Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65252#p65252</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65250#p65250" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>Malcev пишет:</cite><blockquote><div class="codebox"><pre><code>~LButton::
If (A_TimeSincePriorHotkey&lt;400) and (A_ThisHotkey=A_PriorHotkey)
{
   MouseGetPos x2, y2
   Msgbox, % Abs(x1 - x2)
   If Abs(x1 - x2) &lt; 5
   Msgbox, You double clicked on something
}
Else
MouseGetPos x1, y1
Return</code></pre></div></blockquote></div><p>Только пятая строчка наверное так должна выглядеть?<br /></p><div class="codebox"><pre><code>
If (Abs(x1 - x2) &lt; 5) and (Abs(y1 - y2) &lt; 5)</code></pre></div>]]></content>
			<author>
				<name><![CDATA[Pokerist]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24990</uri>
			</author>
			<updated>2012-10-30T13:18:03Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65250#p65250</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65243#p65243" />
			<content type="html"><![CDATA[<div class="codebox"><pre><code>~LButton::
If (A_TimeSincePriorHotkey&lt;400) and (A_ThisHotkey=A_PriorHotkey)
{
   MouseGetPos x2, y2
   Msgbox, % Abs(x1 - x2)
   If Abs(x1 - x2) &lt; 5
   Msgbox, You double clicked on something
}
Else
MouseGetPos x1, y1
Return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[Malcev]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26930</uri>
			</author>
			<updated>2012-10-30T10:49:07Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65243#p65243</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65235#p65235" />
			<content type="html"><![CDATA[<div class="quotebox"><blockquote><p>поскольку код совершенно не понял.</p></blockquote></div><p>Не верю ©</p><p>Можно и развернуть условие.<br /></p><div class="codebox"><pre><code>MultiClick(numClick, clickTimeout)
{
    static clickCount
    static priorHotKey
    static priorTickCount

    if (A_ThisHotkey == priorHotKey &amp;&amp; A_TickCount-priorTickCount &lt;= clickTimeout)
        ++clickCount
    else clickCount := 0

    priorHotKey := A_ThisHotkey
    priorTickCount := A_TickCount

    if (clickCount = numClick-1)
        return true
    else return false
}</code></pre></div><p>«Непонятно» не принимается.</p>]]></content>
			<author>
				<name><![CDATA[creature.ws]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26105</uri>
			</author>
			<updated>2012-10-29T21:10:36Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65235#p65235</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65233#p65233" />
			<content type="html"><![CDATA[<p>Это я сумею. Вот в каком месте кода встроить эту проверку - не представляю, поскольку код совершенно не понял.</p>]]></content>
			<author>
				<name><![CDATA[Pokerist]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24990</uri>
			</author>
			<updated>2012-10-29T20:34:57Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65233#p65233</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65228#p65228" />
			<content type="html"><![CDATA[<p>Определяйте при клике координаты мыши, сравнивайте с ранее сохранёнными координатами предыдущего клика, сохраняйте текущие координаты в качестве «предыдущих».</p>]]></content>
			<author>
				<name><![CDATA[creature.ws]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26105</uri>
			</author>
			<updated>2012-10-29T19:04:22Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65228#p65228</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65226#p65226" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>Malcev пишет:</cite><blockquote><p><a href="http://www.autohotkey.com/docs/commands/SysGet.htm">http://www.autohotkey.com/docs/commands/SysGet.htm</a><br /></p><div class="quotebox"><blockquote><p>36, 37&nbsp; SM_CXDOUBLECLK, SM_CYDOUBLECLK: Width and height of the rectangle around the location of a first click in a double-click sequence, in pixels. The second click must occur within this rectangle for the system to consider the two clicks a double-click. (The two clicks must also occur within a specified time.)</p></blockquote></div></blockquote></div><p>Я наверное не точно сформулировал. Я имею ввиду, что при использовании кода из сообщения #2, два быстрых клика на расстоянии в 100 пикселей засчитыватся как даблклик.&nbsp; Хотелось бы этого избежать.</p>]]></content>
			<author>
				<name><![CDATA[Pokerist]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24990</uri>
			</author>
			<updated>2012-10-29T17:58:45Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65226#p65226</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65225#p65225" />
			<content type="html"><![CDATA[<p>И ещё одно. Если окно неактивно, то двойной клик в него не засчитывается. Приходится делать &quot;тройной&quot;. Можно это как-то побороть?<br /> Речь идёт о коде из сообщения #2.</p>]]></content>
			<author>
				<name><![CDATA[Pokerist]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24990</uri>
			</author>
			<updated>2012-10-29T17:55:53Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65225#p65225</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65222#p65222" />
			<content type="html"><![CDATA[<p><a href="http://www.autohotkey.com/docs/commands/SysGet.htm">http://www.autohotkey.com/docs/commands/SysGet.htm</a><br /></p><div class="quotebox"><blockquote><p>36, 37&nbsp; SM_CXDOUBLECLK, SM_CYDOUBLECLK: Width and height of the rectangle around the location of a first click in a double-click sequence, in pixels. The second click must occur within this rectangle for the system to consider the two clicks a double-click. (The two clicks must also occur within a specified time.)</p></blockquote></div>]]></content>
			<author>
				<name><![CDATA[Malcev]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26930</uri>
			</author>
			<updated>2012-10-29T17:05:59Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65222#p65222</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65221#p65221" />
			<content type="html"><![CDATA[<div class="quotebox"><blockquote><p>Pokerist разве пример во втором сообщении содержит таймеры?</p></blockquote></div><p>Понял. <img src="//forum.script-coding.com/img/smilies/wink.png" width="15" height="15" /></p><p> А как бы второй клик ещё ограничить по расстоянию от первого? Чтобы это срабатывало именно как настощий двойной клик. Допустим если больше 3-5 пикселей между местами кликов - то не защитывается.</p>]]></content>
			<author>
				<name><![CDATA[Pokerist]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24990</uri>
			</author>
			<updated>2012-10-29T16:20:07Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65221#p65221</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK : двойной клик и около.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=65218#p65218" />
			<content type="html"><![CDATA[<div class="quotebox"><blockquote><p>, firstpress - это что такое?</p></blockquote></div><p>— огрызок первоначального варианта кода.<br /><strong>&amp;&amp; !doubleClick</strong> — эта переменная используется и хранится между вызовами для идентификации «пар кликов». Иначе при количестве кликов более 2-х каждый последующий быстрый клик интерпретируется как двойной (с учетом предыдущего)<br /><strong>Pokerist</strong> разве пример во втором сообщении содержит таймеры?</p>]]></content>
			<author>
				<name><![CDATA[creature.ws]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26105</uri>
			</author>
			<updated>2012-10-29T15:18:37Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=65218#p65218</id>
		</entry>
</feed>
