github a shit

fuck
This commit is contained in:
MallocNull 2014-10-19 16:07:35 -05:00
parent 69cb7b358a
commit 51a8fdda5b

View file

@ -17,7 +17,6 @@ namespace bot {
static int currentMessage; static int currentMessage;
public static void reloadContext(FirefoxDriver d) { public static void reloadContext(FirefoxDriver d) {
<<<<<<< HEAD
while(true) { while(true) {
try { try {
List<IWebElement> chatdata = d.FindElement(By.Id("chatList")).FindElements(By.TagName("div")).ToList(); List<IWebElement> chatdata = d.FindElement(By.Id("chatList")).FindElements(By.TagName("div")).ToList();
@ -29,14 +28,12 @@ namespace bot {
break; break;
} catch(Exception shoehorn) {} } catch(Exception shoehorn) {}
} }
=======
List<IWebElement> chatdata = d.FindElement(By.Id("chatList")).FindElements(By.TagName("div")).ToList(); List<IWebElement> chatdata = d.FindElement(By.Id("chatList")).FindElements(By.TagName("div")).ToList();
messageDivSize = chatdata.Count; messageDivSize = chatdata.Count;
foreach(IWebElement we in chatdata) { foreach(IWebElement we in chatdata) {
if(Int32.Parse(we.GetAttribute("id").Substring(we.GetAttribute("id").LastIndexOf('_') + 1)) > currentMessage) if(Int32.Parse(we.GetAttribute("id").Substring(we.GetAttribute("id").LastIndexOf('_') + 1)) > currentMessage)
currentMessage = Int32.Parse(we.GetAttribute("id").Substring(we.GetAttribute("id").LastIndexOf('_') + 1)); currentMessage = Int32.Parse(we.GetAttribute("id").Substring(we.GetAttribute("id").LastIndexOf('_') + 1));
} }
>>>>>>> origin/master
if(d.FindElement(By.Id("audioButton")).GetAttribute("class").ToLower() == "button") if(d.FindElement(By.Id("audioButton")).GetAttribute("class").ToLower() == "button")
d.FindElement(By.Id("audioButton")).Click(); d.FindElement(By.Id("audioButton")).Click();
} }