Android中文網頁
http://code.google.com/intl/zh-TW/android/index.html
Android Developers
http://developer.android.com/index.html
討論板 Android 中文資源站
http://android.cool3c.com/
Android-x86 - Porting Android to x86
http://www.android-x86.org/
Android的Launcher研究:客製化桌面UI
http://www.jollen.org/blog/2009/07/android-os-launcher-app.html
深入淺出Android
http://code.google.com/p/androidbmi/wiki/DiveIntoAndroid
從Home Screen看Android
http://walkingice.twbbs.org/blog/archives/922
Android課程教學
http://blog.chinatimes.com/tomsun/category/6165.html
Android Widget Design
http://developer.android.com/guide/practices/ui_guidelines/widget_design.html
Android Widget 開發流程
http://tonycube.blogspot.com/2009/12/android-widget.html
Android Opensource Project
http://source.android.com/source/index.html
Jollen's Blog ::Android 教學
http://www.jollen.org/blog/android_os/
ADW Launcher
http://code.google.com/p/adw-launcher-android/
https://github.com/AnderWeb/android_packages_apps_Launcher
YSL的程式天堂
http://ysl-paradise.blogspot.com/2009/07/android-analogclock-1.html
http://ysl-paradise.blogspot.com/2009/08/android-app-widgets-2.html
[Android]控制飛航模式(Airplane Mode)開啟/關閉
http://abgne.tw/android/android-code-snippets/android-control-airplane-mode-enabled.html
2009年10月13日 星期二
取得檔案大小
/* 這部份的程式碼 雖然可以正常取得大小,但對簡體字不支援(雖然有時會找得到)
* 但是最重要的是這些程式碼在XP中執行時檔案or資料夾會被lock住無法修改
const char* szPath= path.t_str(); //path.c_str();
WIN32_FIND_DATA wfd;
ZeroMemory(&wfd, sizeof(WIN32_FIND_DATA));
FindFirstFile(szPath, &wfd);
return wfd.nFileSizeLow;
*/
//取得檔案大小
//以下做法可以使檔案Lock住的問題得以解決
TSearchRec sr;
double fsize = 0;
if( FindFirst( path, faAnyFile, sr ) == 0 )
{
fsize = (double)sr.Size;
}
FindClose( sr );
return fsize;
* 但是最重要的是這些程式碼在XP中執行時檔案or資料夾會被lock住無法修改
const char* szPath= path.t_str(); //path.c_str();
WIN32_FIND_DATA wfd;
ZeroMemory(&wfd, sizeof(WIN32_FIND_DATA));
FindFirstFile(szPath, &wfd);
return wfd.nFileSizeLow;
*/
//取得檔案大小
//以下做法可以使檔案Lock住的問題得以解決
TSearchRec sr;
double fsize = 0;
if( FindFirst( path, faAnyFile, sr ) == 0 )
{
fsize = (double)sr.Size;
}
FindClose( sr );
return fsize;
2009年8月21日 星期五
2009年8月11日 星期二
Python + Webkit
要在Python中加入Webkit的內容其實非常容易
首先第一步當然是
import webkit
然後產生webkit元件
self.web_view = webkit.WebView()
接下來就是將webkit的畫面放進準備好的容器中
如一個Box這邊用的是一個box
self.web_box.add(self.web_view)
再來就是設定webkit要顯示的網頁
以Google為例
self.web_view.open("http://www.google.com.tw")
這樣就完成了...網頁的內容就會呈現在你想要顯示的位置了
首先第一步當然是
import webkit
然後產生webkit元件
self.web_view = webkit.WebView()
接下來就是將webkit的畫面放進準備好的容器中
如一個Box這邊用的是一個box
self.web_box.add(self.web_view)
再來就是設定webkit要顯示的網頁
以Google為例
self.web_view.open("http://www.google.com.tw")
這樣就完成了...網頁的內容就會呈現在你想要顯示的位置了
2009年2月23日 星期一
[引用]OpenSync藍芽同步
來源: ChinaUnix博客 日期: 2008.07.06 21:39
http://blog.chinaunix.net/u2/72995/showart_1074534.html
誰再說Linux易用我要抽他了...
1,開啟手機藍牙
2,找到藍牙MAC和SyncMLClient的Chanel
hcitool scan
找到手機的藍牙位址,然後運行
sdptool browser
在結果中找到SyncMLClient一段:
Service Name: SyncMLClient
Service RecHandle: 0x10023
Service Class ID List:
UUID 128: 00000002-0000-1000-8000-0002ee000002
Protocol Descriptor List:
"L2CAP" (0x0100)
"RFCOMM" (0x0003)
Channel: 10
"OBEX" (0x0008)
Language Base Attr List:
code_ISO639: 0x454e
encoding: 0x6a
base_offset: 0x100
Profile Descriptor List:
"" (0x00000002-0000-1000-8000-0002ee000002)
Version: 0x0100
注意其中的Channel 10
3,測試:
export MAC=藍牙地址
export CHANNEL=10
syncml-obex-client -b $MAC $CHANNEL --slow-sync text/x-vcard Contacts --wbxml --identifier "PC Suite"
syncml-obex-client -b $MAC $CHANNEL --slow-sync text/x-vcalendar Calendar --wbxml --identifier "PC Suite"
4,使用msynctool和evolution
msynctool --addgroup mysync
msynctool --addmember mysync syncml-obex-client
msynctool --addmember mysync evo2-sync
配置syncml-obex-client
msynctool --configure mysync 1
主要是修改:
填寫你的藍牙MAC
填寫10
在檔最後前面填寫這一段:
Contacts
contact
vcard30
Calendar
event
vevent20
evo2-plugin不需要配置,如果需要配置就用msynctool --configure mysync 2
5,發現syncobj,否則會提示錯誤:
msynctool --discover mysync 1
msynctool --discover mysync 2
6,同步
msynctool --sync
http://blog.chinaunix.net/u2/72995/showart_1074534.html
誰再說Linux易用我要抽他了...
1,開啟手機藍牙
2,找到藍牙MAC和SyncMLClient的Chanel
hcitool scan
找到手機的藍牙位址,然後運行
sdptool browser
在結果中找到SyncMLClient一段:
Service Name: SyncMLClient
Service RecHandle: 0x10023
Service Class ID List:
UUID 128: 00000002-0000-1000-8000-0002ee000002
Protocol Descriptor List:
"L2CAP" (0x0100)
"RFCOMM" (0x0003)
Channel: 10
"OBEX" (0x0008)
Language Base Attr List:
code_ISO639: 0x454e
encoding: 0x6a
base_offset: 0x100
Profile Descriptor List:
"" (0x00000002-0000-1000-8000-0002ee000002)
Version: 0x0100
注意其中的Channel 10
3,測試:
export MAC=藍牙地址
export CHANNEL=10
syncml-obex-client -b $MAC $CHANNEL --slow-sync text/x-vcard Contacts --wbxml --identifier "PC Suite"
syncml-obex-client -b $MAC $CHANNEL --slow-sync text/x-vcalendar Calendar --wbxml --identifier "PC Suite"
4,使用msynctool和evolution
msynctool --addgroup mysync
msynctool --addmember mysync syncml-obex-client
msynctool --addmember mysync evo2-sync
配置syncml-obex-client
msynctool --configure mysync 1
主要是修改:
填寫你的藍牙MAC
填寫10
在檔最後前面填寫這一段:
Contacts
contact
vcard30
Calendar
event
vevent20
evo2-plugin不需要配置,如果需要配置就用msynctool --configure mysync 2
5,發現syncobj,否則會提示錯誤:
msynctool --discover mysync 1
msynctool --discover mysync 2
6,同步
msynctool --sync
2009年2月4日 星期三
BCB中使用Libcurl
很多OpenSource的程式有支援Window系統
也有很多是以VS開發的
當然...大部份的DLL套件也都是為VS而開發
而BCB要使用這些DLL套件必須要有BCB可以看得懂的點LIB
不然就要自已動態載入要用的Funcution這樣十分的費工
這邊用的方法就是直接產生Lib檔方便讀取的方法
首先到官網下載新的libcurl的binary
先把include中的curl放到系統中的BCB中的include資料夾中
然後將bin資料夾中的.dll檔一一做出對應的.lib檔...做法為
implib -a -c -f xxx.lib xxx.dll ::a switch force add _ alias to MS cdecl
接著把這些檔案放到你的程式的目錄中
並將這些.lib檔加入專案之中
就可以開始用libcurl開發程式了
這方法在其他的套件應該也適用
也有很多是以VS開發的
當然...大部份的DLL套件也都是為VS而開發
而BCB要使用這些DLL套件必須要有BCB可以看得懂的點LIB
不然就要自已動態載入要用的Funcution這樣十分的費工
這邊用的方法就是直接產生Lib檔方便讀取的方法
首先到官網下載新的libcurl的binary
先把include中的curl放到系統中的BCB中的include資料夾中
然後將bin資料夾中的.dll檔一一做出對應的.lib檔...做法為
implib -a -c -f xxx.lib xxx.dll ::a switch force add _ alias to MS cdecl
接著把這些檔案放到你的程式的目錄中
並將這些.lib檔加入專案之中
就可以開始用libcurl開發程式了
這方法在其他的套件應該也適用
訂閱:
文章 (Atom)