#!/usr/bin/python

import wnck
import re
import time
import os

def process_window(w, y, h):
    w.make_below()
    w.set_fullscreen(True)
    w.stick()
    w.set_skip_pager(True)
    w.set_skip_tasklist(True)

#os.system ("/home/paulus/.bggen/runall &")
os.system ("xhost +SI:localuser:inkvizitor68sl")
os.system ("sudo -Hbu inkvizitor68sl /usr/bin/firefox \"http://st.yandex-team.ru/filter?resolution=empty%28%29&assignee=inkvizitor68sl\" \"https://golem.yandex-team.ru/events.sbml?resp=inkvizitor68sl%2C%20&show_developer=on\" \"http://gagarin.corba.yandex.net/ganglia/zombie/graphs.html?config=corba_many\"")

time.sleep(2)

screen = wnck.screen_get_default()
screen.force_update()

for window in screen.get_windows():
    if window.has_name():
        name = window.get_name()
        if re.search('Mozilla Firefox', name):
            process_window(window, -1000, 779)

