diff options
author | Arne Georg Gleditsch <argggh@taniquetil.(none)> | 2009-08-15 12:59:34 +0200 |
---|---|---|
committer | Arne Georg Gleditsch <argggh@taniquetil.(none)> | 2009-08-15 12:59:34 +0200 |
commit | 18bbb85315b190ccf5698fab3a39b576e7a2dbcd (patch) | |
tree | 5231e076ef9fbe99765f0846c7ea14ea85b191d4 /lib/LXRng/Context.pm | |
parent | ca7960590a140fa516aa3e979ef43b655d7292be (diff) |
Make Ajax interface default for Gecko and Opera browsers.
Diffstat (limited to 'lib/LXRng/Context.pm')
-rw-r--r-- | lib/LXRng/Context.pm | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/LXRng/Context.pm b/lib/LXRng/Context.pm index bf717ab..fe1a0fe 100644 --- a/lib/LXRng/Context.pm +++ b/lib/LXRng/Context.pm @@ -54,6 +54,11 @@ sub new { $$self{'prefs'} = { map { /^(.*?)(?:=(.*)|)$/; ($1 => $2) } @prefs }; } + else { + if ($args{'query'}->user_agent() =~ /(Gecko|Opera)\//) { + $$self{'prefs'}{'navmethod'} = 'ajax'; + } + } foreach my $tree (keys %$config) { my $base = $$config{$tree}{'base_url'}; $base =~ s,^https?://[^/]+,,; |