[Vala] Fisrt start in ATK(bad)




I'm trying to get into the ATK API for reading GTK widgets text, but I my first try is not great.
I've read this document:
http://developer.gnome.org/accessibility-devel-guide/3.0/id232879.html.en
Sadly, it is the most useful document for ATK client.

I tried the first one, but with no luck.
Here is source:

using GLib;
using Atk;
using Gtk;

void _my_focus_tracker (Atk.Object object) {
    stdout.printf ("Tracked!\n");
}

int main (string[] args) {
    Gtk.init (ref args);
    Util.add_focus_tracker (_my_focus_tracker);
    
    Gtk.Window window1 = new Gtk.Window ();    
    window1.show ();
    
    Gtk.Window window2 = new Gtk.Window ();    
    window2.show ();
    
    Gtk.main ();
    
    return 0;
}

But no matter how many times I change the focus from window1 to window2, no output.
Does someone here knows why?

Tal
                                          


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]