<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[Серый форум &mdash; AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
		<link>https://forum.script-coding.com/viewtopic.php?id=14351</link>
		<atom:link href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=14351&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[Недавние сообщения в теме «AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?».]]></description>
		<lastBuildDate>Mon, 26 Nov 2018 16:27:06 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=130067#p130067</link>
			<description><![CDATA[<p><strong>teadrinker</strong><br />А вот за это еще больше спасибо.<br /><em>Ушел переделывать некоторые свои скрипты. <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /> </em></p>]]></description>
			<author><![CDATA[null@example.com (Gh0sTG0)]]></author>
			<pubDate>Mon, 26 Nov 2018 16:27:06 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=130067#p130067</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=130066#p130066</link>
			<description><![CDATA[<p>Активировать можно любую вкладку по её ID:<br /></p><div class="codebox"><pre><code>#Persistent
profile := A_Temp
arrUrls := [&quot;http://forum.script-coding.com/&quot;, &quot;https://autohotkey.com/boards/index.php&quot;]
oChrome := new Chrome(profile, arrUrls)
oPage := oChrome.GetActivePage()
id := oChrome.GetPageList()[1].id

MsgBox, Сейчас откроем новую страницу
oPage.Call(&quot;Target.createTarget&quot;, {url: &quot;http://forum.script-coding.com/misc.php?action=rules&quot;})
oPage.Call(&quot;Target.activateTarget&quot;, {targetId: id})</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (teadrinker)]]></author>
			<pubDate>Mon, 26 Nov 2018 16:25:31 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=130066#p130066</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=130065#p130065</link>
			<description><![CDATA[<p><strong>teadrinker</strong>, Но созданная вкладка становится активной. Т.е. потом придется любым удобным методом все равно искать ту, с которой начинал.<br />Но все равно спасибо, приемчик запомню, вроде уже знаю где он может пригодиться.</p>]]></description>
			<author><![CDATA[null@example.com (Gh0sTG0)]]></author>
			<pubDate>Mon, 26 Nov 2018 16:10:42 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=130065#p130065</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=130064#p130064</link>
			<description><![CDATA[<div class="codebox"><pre><code>#Persistent
profile := A_Temp
arrUrls := [&quot;http://forum.script-coding.com/&quot;, &quot;https://autohotkey.com/boards/index.php&quot;]
oChrome := new Chrome(profile, arrUrls)
oPage := oChrome.GetActivePage()
MsgBox, Сейчас откроем новую страницу
oPage.Call(&quot;Target.createTarget&quot;, {url: &quot;http://forum.script-coding.com/misc.php?action=rules&quot;})</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (teadrinker)]]></author>
			<pubDate>Mon, 26 Nov 2018 16:01:58 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=130064#p130064</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=130063#p130063</link>
			<description><![CDATA[<p><strong>teadrinker</strong><br />В смысле? Не очень понял что вы имеете ввиду. Можно как то вставить задержку между созданием вкладок не запихивая в цикл run chrome.exe с каждой ссылкой и слипом??</p>]]></description>
			<author><![CDATA[null@example.com (Gh0sTG0)]]></author>
			<pubDate>Mon, 26 Nov 2018 15:58:53 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=130063#p130063</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=130062#p130062</link>
			<description><![CDATA[<p><strong>ypppu</strong><br />Вроде все поправил.</p>]]></description>
			<author><![CDATA[null@example.com (Gh0sTG0)]]></author>
			<pubDate>Mon, 26 Nov 2018 15:54:15 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=130062#p130062</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=130061#p130061</link>
			<description><![CDATA[<p><strong>Gh0sTG0</strong>, вкладки можно задать сразу при создании объекта. Если нужно новую открыть позже, тоже делается через объект, как исправитесь, могу подсказать.</p>]]></description>
			<author><![CDATA[null@example.com (teadrinker)]]></author>
			<pubDate>Mon, 26 Nov 2018 15:52:35 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=130061#p130061</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=130060#p130060</link>
			<description><![CDATA[<p><span style="color: green"><strong>Gh0sTG0</strong>, проставьте недостающие точки в сообщениях!</span><br /><a href="http://forum.script-coding.com/viewtopic.php?pid=130059#p130059">http://forum.script-coding.com/viewtopi … 59#p130059</a><br /><a href="http://forum.script-coding.com/viewtopic.php?pid=130056#p130056">http://forum.script-coding.com/viewtopi … 56#p130056</a><br /><a href="http://forum.script-coding.com/viewtopic.php?pid=129763#p129763">http://forum.script-coding.com/viewtopi … 63#p129763</a><br /><a href="http://forum.script-coding.com/viewtopic.php?pid=129623#p129623">http://forum.script-coding.com/viewtopi … 23#p129623</a><br /><a href="http://forum.script-coding.com/viewtopic.php?pid=129464#p129464">http://forum.script-coding.com/viewtopi … 64#p129464</a><br /><a href="http://forum.script-coding.com/viewtopic.php?pid=129462#p129462">http://forum.script-coding.com/viewtopi … 62#p129462</a><br /><a href="http://forum.script-coding.com/viewtopic.php?pid=129459#p129459">http://forum.script-coding.com/viewtopi … 59#p129459</a><br /><a href="http://forum.script-coding.com/viewtopic.php?pid=129285#p129285">http://forum.script-coding.com/viewtopi … 85#p129285</a><br /><a href="http://forum.script-coding.com/viewtopic.php?pid=129282#p129282">http://forum.script-coding.com/viewtopi … 82#p129282</a><br /><a href="http://forum.script-coding.com/viewtopic.php?pid=129240#p129240">http://forum.script-coding.com/viewtopi … 40#p129240</a></p>]]></description>
			<author><![CDATA[null@example.com (ypppu)]]></author>
			<pubDate>Mon, 26 Nov 2018 15:44:58 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=130060#p130060</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=130059#p130059</link>
			<description><![CDATA[<p><strong>teadrinker</strong><br />Переделал в другой вариант, вроде работает.<br /></p><div class="codebox"><pre><code>urlList		:= &quot;&quot;
for index, value in elL
	urlList	.= ((A_Index = 1) ? &quot;&quot; : &quot; &quot;) . value

Run, % &quot;chrome.exe &quot; urlList</code></pre></div><p>Вроде получилось неплохо, они открываются.<br />Опять сработала магическая штука &quot;напиши на script-coding и найдешь ответ, даже если тебе его не напишут прямо, ты все равно его в ближайшее время нагуглишь&quot;. Спасибо.</p>]]></description>
			<author><![CDATA[null@example.com (Gh0sTG0)]]></author>
			<pubDate>Mon, 26 Nov 2018 15:31:07 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=130059#p130059</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=130058#p130058</link>
			<description><![CDATA[<p>А зачем нужно именно эмулировать нажатие средней кнопкой? Просто откройте новую вкладку с нужным url.</p>]]></description>
			<author><![CDATA[null@example.com (teadrinker)]]></author>
			<pubDate>Mon, 26 Nov 2018 15:27:29 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=130058#p130058</guid>
		</item>
		<item>
			<title><![CDATA[AHK: chrome.ahk как имитировать клик средней мышкой по ссылке?]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=130056#p130056</link>
			<description><![CDATA[<p>Добрый вечер. Вопрос на стыке ahk и хромовской консоли. Может я слепой, но так и не нашел вменяемых безЧСВшных объяснений в интернете, которые бы заработали из ahk под chrome.ahk.</p><p>Как сделать реакцию = клику средней кнопкой мыши по ссылке? Т.е. открыть ссылку в новой фоновой вкладке?</p><div class="codebox"><pre><code>PageInst := Chrome.GetPage(1)
numEl := PageInst.Evaluate(&quot;document.getElementsByClassName(&#039;thumb&#039;).length;&quot;).Value
Loop %numEl%
{
	lnk := PageInst.Evaluate(&quot;document.getElementsByClassName(&#039;thumb&#039;)[&quot; . A_Index - 1 . &quot;].href;&quot;)
	[по идее я получил ссылку на страницу куда надо идти. если вместо href делать click() он откроет все подряд в той же вкладке...]
}</code></pre></div><p>Либо скажите, &quot;это невозможно&quot; и я пойду дальше юзать свой тупой костыльный цикл.<br /></p><div class="codebox"><pre><code>	for index, element in elL
	{
		Sleep 300
		Send ^t
		Sleep 500
		Clipboard := element
		Sleep 200
		Send ^v
		Sleep 200
		Send {Enter}
	}</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (Gh0sTG0)]]></author>
			<pubDate>Mon, 26 Nov 2018 15:02:30 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=130056#p130056</guid>
		</item>
	</channel>
</rss>
