E71.RU E71.RU
Добро пожаловать, Гость! [ ИнфоБлокОбновленияУчастникиПравилаПоискFAQ-ЧаВо ] Регистрация недоступна • Вход RSS
Пятница, 22.09.2017
1 терапевт - это 1024 гигапевта или 1048576 мегапевтов.
Страница 1 из 11
Модератор форума: Maggot 
Форум » Мобильный мир » English-speaking Forum » Some New Functions Added to the Library
Some New Functions Added to the Library
BingKДата: Суббота, 20.09.2008, 18:14 | Сообщение # 1
Подполковник
Имя: BingK
С нами с: 03.08.2008
Сообщений: 100
Награды: 0
Модель телефона: S75/S68/SK65
Статус: Offline
Code

typedef struct
{
   int flag; //8, 0
   int (*onkey)(void *, GUI_MSG *);
   void (*ghook)(void *, int );
   void *proc3; //locret
   const int *softkeys;
   const SOFTKEYSTAB *softkeystab;
   int flags2; //1
   int lgp_null; //?
   const int *icons;
   int zero0; //0
   int _2; //2
   int _100;
   int _101;
   int zero1; //0
}POPUP_DESC;

#pragma swi_number=0x2A3
__swi __arm void UpdateMenuCursorItem(void *gui, int n);
//thumb
//pattern_NSG=??,B5,??,1C,_blf(??,B5,??,1C,??,1C,??,??,??,??,??,1C,??,34,??,69,??,22,??,32,??,42,??,59),??,1C+1

#pragma swi_number=0x2A4
__swi __arm void *GetMenuGUI(void *malloc_adr, void *mfree_adr);
//thumb
//pattern_NSG=??,B5,??,1C,??,20,??,1C,??,00,??,47,??,1C,??,1C,??,??,??,??,??,BD+1

#pragma swi_number=0x2A5
__swi __arm void *GetMultiLinesMenuGUI(void *malloc_adr, void *mfree_adr);
//thumb
//pattern_NSG=??,B5,??,1C,??,20,??,1C,??,01,??,47,??,1C,??,1C,??,??,??,??,??,BD+1

#pragma swi_number=0x2A6
__swi __arm void SetHeaderToMenu(void *gui, const HEADER_DESC *hdr, void *malloc_adr);
//thumb
//pattern_NSG=??,B5,??,1C,??,22,_blf(??,B5,??,1C,??,1C,??,1C,??,??,??,??,??,28,??,D1,??,2A),??,BD+1

#pragma swi_number=0x2A7
__swi __arm void SetMenuToGUI(void *gui, const void *menu_desc);//MENU_DESC,ML_MENU_DESC
//thumb
//pattern_NSG=??,B5,??,1C,??,1C,??,??,??,??,??,21,??,1C,_blf(??,1C,??,68,??,20,??,69,??,43,??,D0,??,20,??,47),??,1C,??,36,??,36,??,28,??,D0,+1        

#pragma swi_number=0x2A8
__swi __arm int GetMenuItemCount(void *gui);
//thumb
//pattern_NSG=??,21,??,31,??,58,??,30,??,69,??,29,??,D0,??,38,??,47+1

//???
#pragma swi_number=0x2A9
__swi __arm int CreatePopupGUI(int flag, void *user_pointer, const POPUP_DESC *, int lgp_msg);
//thumb
//pattern_NSG=??,1C,??,99,??,??,??,??,??,B0,??,BD,??,B5,??,4C,??,1C,??,1C+D

#pragma swi_number=0x2AA
__swi __arm int CreatePopupGUI_ws(int flag, void *user_pointer, const POPUP_DESC *, WSHDR *msg);
//thumb
//pattern_NSG=??,B5,??,1C,??,1C,??,1C,??,49,??,B0,??,48,??,??,??,??,??,1C,??,1C,??,??,??,??,??,49,??,1C,??,??,??,??,??,1C,??,1C,??,??,??,??,??    ,1C,??,1C,??,??,??,??,??,1C,??,99,??,??,??,??,??,B0,??,BD+1

#pragma swi_number=0x2AB
__swi __arm void *GetPopupUserPointer(void *gui);
//thumb
//pattern_NSG=C0,30,00,68,70,47,80,30,40,68,70,47+1

#pragma swi_number=0x2AC
__swi __arm int DeleteSMS(int index, int n); //return 0x3E8
//thumb
//pattern_NSG=??,B5,??,4E,??,1C,??,1C,??,1C,??,49,??,B0,??,??,??,??,??,1C,??,1C+1

#pragma swi_number=0x2AD
__swi __arm int SetNewSMSToReaded(int index, int _1); //return 0x3E8
//thumb
//pattern_NSG=??,B5,??,1C,??,4C,??,49,??,B0,??,1C,??,??,??,??,??,AB,??,8A,??,1C+1

some examples:

Code
unsigned int CreateMLMenu(const ML_MENU_DESC *menu, const HEADER_DESC *hdr, int start_item, int n_items, void *user_pointer)
{
     void *ma=malloc_adr();
     void *gui=GetMultiLinesMenuGUI(ma, mfree_adr());
     SetMenuToGUI(gui, menu);
     SetMenuItemCount(gui, n_items);
     MenuSetUserPointer(gui, user_pointer);
     SetCursorToMenuItem(gui, start_item);
     SetHeaderToMenu(gui, hdr, ma);
     return (CreateGUI(gui));
}

unsigned int CreateSLMenu(const MENU_DESC *menu, const HEADER_DESC *hdr, int start_item, int n_items, void *user_pointer)
{
         
     void *ma=malloc_adr();
     void *gui=GetMenuGUI(ma, mfree_adr());
     SetMenuToGUI(gui, menu);
     SetMenuItemCount(gui, n_items);
     MenuSetUserPointer(gui, user_pointer);
     SetCursorToMenuItem(gui, start_item);
     SetHeaderToMenu(gui, hdr, ma);
     return (CreateGUI(gui));
}

Code
void UpdateMenuCursorItem(void *gui, int n);

is a little the same as :

Code
SetCursorToMenuItem(gui, n);
RefreshGUI();

but if you use MenuSearchCallBack, UpdateMenuCursorItem is better.

int DeleteSMS(int index, int n);
int SetNewSMSToReaded(int index, int _1);

index = (the byte position of the sms in sms.dat -2)/(sizeof(PDU))+1;

update:
int DeleteSMS(int index, int n);

some of the pattern is for NEWSGOLD only.
and they are found for E71v45, not tested.

Code

//E71v45

0A8C: 0xA0953319   ; 2A3:  __thumb void UpdateMenuCursorItem(void *gui, int n)
0A90: 0xA0950125   ; 2A4:  __thumb void *GetMenuGUI(void *malloc_adr, void *mfree_adr)
0A94: 0xA0957479   ; 2A5:  __thumb void *GetMultiLinesMenuGUI(void *malloc_adr, void *mfree_adr)
0A98: 0xA094F739   ; 2A6:  __thumb void SetHeaderToMenu(void *gui, const HEADER_DESC *hdr, void *malloc_adr)
0A9C: 0xA09540DB   ; 2A7:  __thumb void SetMenuToGUI(void *gui, const void *menu_desc)
0AA0: 0xA0950F33   ; 2A8:  __thumb int GetMenuItemCount(void *gui)
0AA4: 0xA094E8C1   ; 2A9:  __thumb int CreatePopupGUI(int flag, void *user_pointer, const POPUP_DESC *, int lgp_msg)
0AA8: 0xA094E803   ; 2AA:  __thumb int CreatePopupGUI_ws(int flag, void *user_pointer, const POPUP_DESC *, WSHDR *msg)
0AAC: 0xA09572F9   ; 2AB:  __thumb void *GetPopupUserPointer(void *gui)
0AB0: 0xA0B56FB3   ; 2AC:  __thumb int DeleteSMS(int index, int _1)
0AB4: 0xA0B575C5   ; 2AD:  __thumb int SetNewSMSToReaded(int index, int _1)


S7Csw47[MasterPack+ELFPack]
S68Csw51[MasterPack+ELFPack]
SK6Csw50[ELFPack]
DCA- 510/540/110/140
I am From China !


Сообщение отредактировано BingK - Воскресенье, 21.09.2008, 10:27
 
Форум » Мобильный мир » English-speaking Forum » Some New Functions Added to the Library
Страница 1 из 11
Поиск:
Использование материалов сайта возможно только при согласовании с администрацией