<?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=15550&amp;type=atom" />
	<updated>2020-07-29T02:15:20Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=15550</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Отслеживание нажатий клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=141195#p141195" />
			<content type="html"><![CDATA[<p><strong>Alectric</strong><br />Я додумался до другое решение оно мне больше подходит ну я его оставлю сдесь может кому пригодится<br />Сразу объясню почему P должна быть больше 0 для срабатывания потому что false = 0 а true = 1.<br />Ну можно и заменить на<br />Code</p><p>if P = 1</p><p> и тд</p><p>Code</p><p>P := false<br />R := false</p><p>end:: <br />P := true<br />R := false<br />return</p><p>Home::<br />P := false<br />R := true<br />return</p><p>Delete::<br />P := false<br />R := false<br />return</p><p>~RButton &amp; ~LButton:: <br />Loop 1<br />If (P &gt; 0)<br />{<br />Sleep, 1<br />Loop 1&nbsp; </p><p>If ((GetKeyState(&quot;LButton&quot;, &quot;P&quot;)) || (GetKeyState (&quot;RButton&quot;, &quot;P&quot;)))<br />{<br />MsgBox, Нажатие лкм и пкм<br />&nbsp; &nbsp; }<br />&nbsp; &nbsp; else<br />&nbsp; &nbsp; break<br />&nbsp; &nbsp; <br />Sleep, 1&nbsp; &nbsp; <br />Loop 1&nbsp; &nbsp; &nbsp;<br />If ((GetKeyState(&quot;LButton&quot;, &quot;P&quot;)) || (GetKeyState (&quot;RButton&quot;, &quot;P&quot;)))<br />{&nbsp; &nbsp; &nbsp; &nbsp; <br />MsgBox, Удержание<br />&nbsp; &nbsp; }<br />&nbsp; &nbsp; else<br />&nbsp; &nbsp; break&nbsp; &nbsp; <br /> }<br /> else<br />&nbsp; &nbsp;break</p><p>return</p>]]></content>
			<author>
				<name><![CDATA[gjifh]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=40994</uri>
			</author>
			<updated>2020-07-29T02:15:20Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=141195#p141195</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Отслеживание нажатий клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=141172#p141172" />
			<content type="html"><![CDATA[<p>Ааа, всё, дошло. <span style="color: #f5f5f5">Тут один человек мозги запарил.</span><br />Там звездочки нужны.<br />Исправил выше.</p>]]></content>
			<author>
				<name><![CDATA[Alectric]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26027</uri>
			</author>
			<updated>2020-07-28T11:02:24Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=141172#p141172</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Отслеживание нажатий клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=141170#p141170" />
			<content type="html"><![CDATA[<p>Плохо проверяли. Проверьте свой вариант с зажатыми модификаторами.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2020-07-28T03:41:37Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=141170#p141170</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Отслеживание нажатий клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=141167#p141167" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>teadrinker пишет:</cite><blockquote><p>Проверяйте, перед тем, что пишете. <img src="//forum.script-coding.com/img/smilies/wink.png" width="15" height="15" /></p></blockquote></div><p>Я проверял. На версии которой пользуюсь работает именно так.</p>]]></content>
			<author>
				<name><![CDATA[Alectric]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26027</uri>
			</author>
			<updated>2020-07-28T02:09:47Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=141167#p141167</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Отслеживание нажатий клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=141159#p141159" />
			<content type="html"><![CDATA[<p>Проверяйте, перед тем, что пишете. <img src="//forum.script-coding.com/img/smilies/wink.png" width="15" height="15" /></p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2020-07-27T17:23:14Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=141159#p141159</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Отслеживание нажатий клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=141158#p141158" />
			<content type="html"><![CDATA[<p>Тогда не будет работать при зажатом Ctrl, Alt, Win или Shift.</p>]]></content>
			<author>
				<name><![CDATA[Alectric]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26027</uri>
			</author>
			<updated>2020-07-27T16:59:16Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=141158#p141158</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Отслеживание нажатий клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=141157#p141157" />
			<content type="html"><![CDATA[<p><strong>Alectric</strong>, все <strong>$</strong> лишние.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2020-07-27T16:48:00Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=141157#p141157</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Отслеживание нажатий клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=141151#p141151" />
			<content type="html"><![CDATA[<div class="codebox"><pre><code>~End::
a:=!a
return

#if a
~*LButton::
tooltip левая
return

~*RButton::
tooltip правая
return

~*MButton::
tooltip средняя
return

~*LButton up::
tooltip левая отпущена
return

~*RButton up::
tooltip правая отпущена
return

~*MButton up::
tooltip средняя отпущена
return


</code></pre></div>]]></content>
			<author>
				<name><![CDATA[Alectric]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26027</uri>
			</author>
			<updated>2020-07-27T15:18:07Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=141151#p141151</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[AHK: Отслеживание нажатий клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=141146#p141146" />
			<content type="html"><![CDATA[<p>Не додумался как правильно оформит заголовок но не суть.<br />Так вот пример мне нужно что-бы при нажатии допустим End Отслеживалось нажатие клавиш мыши при повторном нажатии этой клавиши и указанных клавиш допустим Home и Delete<br />отслеживание клавиш прекратилось <br />Вот до чего додумался я но не работает должным образом</p><div class="codebox"><pre><code>~End::

Sleep, 1
Loop 1     
If GetKeyState(&quot;LButton&quot;, &quot;RButton&quot;) {
        
        Msgbox Клавиши нажаты
    }
    else
    break

Sleep, 1
Loop 1     
If GetKeyState(&quot;LButton&quot;, &quot;RButton&quot;) {
        
        Msgbox Удержание клавиш
    }
    else
    break

return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[gjifh]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=40994</uri>
			</author>
			<updated>2020-07-27T11:39:47Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=141146#p141146</id>
		</entry>
</feed>
