|
ZT from http://forums.precentral.net/web ... addons-1-3-1-a.html9 N8 y" T, u6 O6 Z) L" A- }3 f
' \6 r+ V8 s* \/ N) u* S4 Q
Palm在1.3.1更改了全局搜索设置,使之更加容易添加新的搜索。
: @" v% e0 V1 B' \0 t这里以增加 IMDB 搜索为例.- --- .orig/usr/lib/luna/system/luna-applauncher/app/controllers/global-search-assistant.js
3 m0 R) x2 u$ {1 V - +++ /usr/lib/luna/system/luna-applauncher/app/controllers/global-search-assistant.js9 s6 P2 v0 P, ?3 s# N( r
- @@ -46,6 +46,7 @@
E# z. v. ]' \ - this.limit=40;& m$ |% k2 Q) @
- this.URLs = {
& d0 O/ E0 l' ]( x2 E' W - 'google':$L("www.google.com/m/search?client=ms-palm-webOS&channel=iss&q="),
3 M4 s0 W1 C4 f* ^ - + 'imdb':$L("http://www.imdb.com/find?s=all&q="),/ ?4 e+ X: y+ C) F
- 'wikipedia':$L("http://en.m.wikipedia.org/wiki/Special:Search?search="),
A% L( U8 U3 h: `7 c; w - 'twitter': $L("http://search.twitter.com/search?q="),
6 u" W- @8 k3 i& A1 t" l8 ? - 'yahoo': $L("http://search.yahoo.com/search?p="),0 ~$ q3 N. s3 p/ A, y9 Q: L
- @@ -130,6 +131,7 @@* M; P: X4 b6 j% j
-
" k* A4 P p9 X! l/ d3 ]& c - this.searchEngineList = [{id:"google",title:"Google",imgFile:"images/search-google.png", showImage:"block", showName:"none"},# c; c! l/ N+ R, O6 _8 k
- {id:"map",title:"Google Maps",imgFile:"images/search-maps.png", showImage:"block", showName:"none"},
, Y P+ x, d0 X! b* B) V; R- S - + {id:"imdb",title:"IMDB",imgFile:"images/search-imdb.png", showImage:"block", showName:"none"},
* |% k0 S0 d! h! M7 R - {id:"wikipedia",title:"Wikipedia",imgFile:"images/search-wikipedia.png", showImage:"block", showName:"none"},/ P2 k- O, V9 X* D
- {id:"twitter",title:"Twitter",imgFile:"images/search-twitter.png", showImage:"block", showName:"none"}, ?: n5 V8 a! a* S: U
- ];8 \8 s, k+ c/ V4 X" }5 M* `
- - R) _9 k/ v3 U
- --- .orig/usr/lib/luna/system/luna-applauncher/stylesheets/global-search.css" H# T/ R3 a3 z/ s# v) t3 [
- +++ /usr/lib/luna/system/luna-applauncher/stylesheets/global-search.css
/ J! R/ e7 ]- @( o" d7 { - @@ -139,6 +139,12 @@2 D! x: N/ H8 r3 l
- background: url(../images/search-google.png) center center no-repeat;
- _+ L c% L! D; Z - }
+ R9 J: o( v( z6 A - 3 Y. U. Z u6 T2 z: Y- F
- +.palm-group.search .search-imdb { : e& u& H5 C0 @6 f
- + width: 100%;5 L; E7 ^& V8 L+ x& V) Z8 L
- + height: 52px;
5 F; K. o- b- q2 g5 q5 } - + background: url(../images/search-imdb.png) center center no-repeat;5 ?" C' v+ t \7 ?, K
- +}
}, A, J) P& W) B( E* A/ z. L1 w L - +
! c$ s j$ p0 L* J6 Q# f, |9 T+ k - .palm-group.search .search-maps {
* Z) Y1 n* `9 G# p, r - width: 100%;
5 m( _, l G# c) W8 r; d - height: 52px;
复制代码 |
评分
-
查看全部评分
|