(I'm only two days into WP7, so don't smack me too hard.)
While attempting to debug some Windows Phone 7 behavior via RustyGrom's unlocked images, I stumbled across the whole "/h/ttps issue". This forced me to re-look at how the original mod was performed.
The original method, as outlined in this blog post, involves manipulating the read-only portion of the system registry -- default.hv. Doing so invalidates its baked in signature, wrecking havoc (manifesting itself as broken /h/ttps and other assorted crappiness).
To work around this, I instead made a change to an internal function within AppMetadata.dll, causing all requests to blacklist to return empty handed. (A one byte change at 0xAC8A, 75->EB.) That unlocks the applications on the splash screen.
To unlock the "settings", however, is a trickier matter and involves those irritating "SecureItem" values and the parsing code within SplashSettingsDll.dll. (If you're wondering what the GUIDs mean, there's a translation to canonical names in 8C9C0C34-B77D-45FB-9E4E-D53AC5900244.rgu).
Code:
Themes = {165705CD-200B-4b23-961D-E3F66F844514}
Sounds = {92F34415-4D78-4430-9933-D2DEEA0C9D3D}
FlightMode = {1DEF9B7D-2322-40eb-A007-16A75D5CDA62}
Accessibility = {C5A90F1C-112F-43d3-8C80-C5D1746F3B68}
WiFi = {291A7CF3-48C4-4319-A6F6-E4BABFCCB8E8}
Bluetooth = {BFBBBF37-35E3-447b-BE65-DFC149EF614F}
Location = {41954AAF-E1C4-4b81-A5EC-A5C8961FE34C}
CellularConn = {FD427838-F373-40a3-9FEC-76C6CFFAFC04}
Accounts = {87F5E764-4AB3-4664-B2A3-BE00A2E8AF4A}
Brightness = {B7AFEE4D-7738-48df-8CA4-588D14AE256B}
TouchKeyboard = {071692BE-EC17-463e-94C7-64FB874A6180}
Regional = {E37398A2-CEAD-423c-9EC2-F43251C0B2CE}
DateTime = {9CB05CAE-D2CF-4409-8E64-352DD8F6FDE2}
PhoneLock = {37966764-79C8-4090-A8CF-FB65D638E529}
Updates = {C956380A-087F-4548-A5F6-CEF3616A55DA}
About = {9DAD8821-3F8C-474f-AB2B-D120BA03AFDC}
Speech = {7D878951-E418-46a3-AF6B-DCB45CD375B9}
Contacts = {2D267C1E-C53A-4718-8032-FAC545DDDF8C}
Photos = {864AAEB9-9419-40f9-BA88-03E986859450}
Messaging = {D651D70D-B141-4d71-8FFB-1004C24FB12B}
Phone = {83171528-D3B9-49b6-BC05-BBB3B4B25460}
IE = {A7DD1D7D-C7CA-4566-A5E7-015C7940276E}
Maps = {21EF1D0A-5EBE-4056-9622-2D9615C967E1}
Search = {90A593C1-F945-4bf7-AB56-A999E425F16F}
OfficeMobile = {5962CFCF-8008-4d55-B048-BDCDD7A90EAB}
Games = {B193A538-115B-4789-93D1-F3981B9D7B11}
Radio = {18916419-df98-4042-bb27-6ae39dbc3310}
FindMyPhone = {1691B767-686D-4934-A844-C0057C6024A0}
Feedback = {BF0D001A-1988-4cf3-81E1-16A1CCAB5DA3}
Marketplace = {1D36BBB8-9EEE-4e30-A72B-77ED9CFF11D1}
Unfortunately, Microsoft decided to put required data in these SecureItem values. It appears this data drives what order the application shows in the Settings list and/or the "type" of task. (Unsure about that last bit.) If this data is empty -- for example, I skip over all the SecureItem parsing -- the item vanishes.
I wrote some assembly to simulate returning order data, in an incrementing fashion (10, 20, 30, ...) -- which was fun -- but utterly useless. I'm obviously not putting this data where it wants it to be. I believe the second parameter to an internal function that handles enumerating all the SecureItems (va 41415066/offset 0x4266) is some sort of structure (with two members?) that's key here.
Without a debugger, probing this structure is nearly impossible -- I'm open to ideas here... The only idea I have is making the application crash on "executing" those members, then using the output window to get the values... but this'll be super difficult to pull off.
(If you could convince a mod to lift the restrictions on my account, that'd be wonderful. I can't post links or do anything useful.)
Thanks for the work.
mod speaking: about the link as you are a new member you need 5 posts before you can post link so only one post left until you can edit and post comment
Great work! One thing I thought about, what about just editing the RGU files to get to the same goal of writing to the registry? It seems like those are applied at boot time and presumably wouldn't be under the 'read only'.
RustyGrom said:
Great work! One thing I thought about, what about just editing the RGU files to get to the same goal of writing to the registry? It seems like those are applied at boot time and presumably wouldn't be under the 'read only'.
Click to expand...
Click to collapse
I don't know much about those files, but each RGU file has a corresponding DSM which appears to have certificate information. I'll see what happens tho. (I'm guessing these files were designed for OEM use.)
Update: Yeah, as I thought. The (signed) default.hv references the RGUs, so you can't just rip one out. And you can't tinker inside because they're signed. You can't replace the DSM either because its root certificate is checked against the baked in few (similar to desktop Windows). Ahhhh. We might be forced to patch up the boot/kernel binaries... that sucks tho.
Update 2: ... and no, you can't replace the RGU/DSM pair with a "valid" one. The files are SHA160 hashed, with the first 16 bytes put into default.hv -- HKEY_LOCAL_MACHINE\System\ObjectStore\RegistryUpdate. I suppose since the hash is truncated, you could -- in theory -- edit a RGU until it generated a similar hash... but that's crazy talk.
Keep up the good work Rafael, I'm sure you will figure out a way around it. You always find the craziest ways around Microsoft's lock-downs. Good Luck and I can't wait to see the results .
Just an update: I was able to build an SDK that works pretty damn well for native WP7 binary creation. After some fiddling with the buggy XIPPort tool and VS2010, I was able to produce a binary that runs just fine in WP7. (Currently, I just replaced Settings3.exe and used the menu's Settings link as an entrypoint.)
Now I can fiddle with more fun things, like accessing the registry and inserting those elusive SecureItems Not sure if those values are checked all the time tho -- if it's a one-time deal, I'll need to "reboot" the home screen.
Code:
INT start(
__in HINSTANCE hInstance,
__in HINSTANCE hPrevInstance,
__in LPWSTR lpCmdLine,
__in int nCmdShow
)
{
NKDbgPrintfW(L"[Hello, WP7. I haz you.]\r\n");
return 0;
}
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Awesome stuff man. This should be extremely valuable once we figure out how to mod the ROM.
Settings3.exe is an application that runs in a normal user context, i.e. isn't very useful. Preload.exe, however -- which is used to insert dummy address book data at boot -- runs at a higher level. I replaced that with my code and was able to edit the registry (blacklist, secureitems) just fine... but it's too late during boot (damn!). The splash screen starts before my code is executed.
Related
Yes, you can give a folder an icon, IE if you make a subfolder under 'programs' , but file explorers also show them :
create a textfile 'icon.lnk' and enter in it :
1#ceshell.dll,-162
save it and make it hidden....
It looks like the -162 is a code for the icon entry, some files take only '0',
(1#repllog.exe,0) ceshell.dll for example allows -142 -144, -147 and -148
Now on to linking other icons to links (program's, mortscripts !), read someting about it here
Johan: I've posted on this elsewhere. The number is an icon offset within the dll/exe. You need an icon viewer/scanner too find the icon offset you need.
V
Hmm, nice, but how do i find these offsets ?
Because I love you
Be careful, sometimes it goes off hunting for half an hour. It's best to count downwards then upwards. You'll get the hang of it! PHM Tools has a very useful dll full of icons.
BTW, don't forget the first numbers before the # are the length of the shortcut string, ie everything after the #. I don't think it ever makes any difference, but it'd make for an interesting buffer overflow exploit I guess.
30#"\Windows\PHMShell32.dll,-173"
http://forum.xda-developers.com/viewtopic.php?p=222846#222846
Phew
Since we're on the subject, I might as well throw this one in for completeness.
You can use an icon NOT from the executable (ie not the default one) by using this kind of syntax:
65#ctlpnl.exe cplmain.cpl,4?\Storage Card\!Install\ftxPBrowser.exe,0
65=length of shortcut string
ctlpnl bit is an example of how to access control panel features (change the 4. You can access tabs where appropriate thus: 4,1 = 1st tab)
Everything after the ? is used to identify the target icon offset in ANOTHER dll/exe.
Change the 0 to specify an offset.
So in this example you're showing the memory control panel, using ftx's default icon.
Enough already! VJOkButt beckons...
V
vijay555 said:
Because I love you /
Click to expand...
Click to collapse
:shock: :roll: :lol:
PHM Tools has a very useful dll full of icons.
Click to expand...
Click to collapse
Got it yesterday !
BTW, don't forget the first numbers before the # are the length of the shortcut string, ie everything after the #. I don't think it ever makes any difference, but it'd make for an interesting buffer overflow exploit I guess.
Click to expand...
Click to collapse
I think it's used for shortcuts that point at "MSCALENDER"IE, not to an executable, to decide what's commandline, and what not...
Phew
Since we're on the subject, I might as well throw this one in for completeness.
You can use an icon NOT from the executable (ie not the default one) by using this kind of syntax:
65#ctlpnl.exe cplmain.cpl,4?\Storage Card\!Install\ftxPBrowser.exe,0
Click to expand...
Click to collapse
YES ! that's what i was looking for ! I created some mortscripts, and if i put them in a Todaylauncher, they all have te same icon, now i can add individual icons !
Works like a charm...
The PHM tools i d/l didn't have the dll with all the icons...
Seems i've misplaced the old one
On to a Icon hunt....
Btw, can you use a .bmp as icon, with offset 0 ?
Don't think so. Use something like Microangelo librarian and import your own bmps into a dll and use that. That's how I use claunch.
V
vijay.. your app's not finding any icons in ceshell.dll on my device - I'd imagine it's supposed to? :>
Tried shell32.exe as well.
It did find the icon for DeviceInformation.exe , though.
Oddly enough, a freeware desktop app has the same thing.. can't find anything in ceshell.dll / shell32.exe, but does find the DeviceInformation.exe icon (resource -103). Weird?
Hmm, never really tried it. Just tried Microangelo on rom dumps of the same files, and same findings. Will look into it on a real device I suppose... Any particular icons you're after?
V
Wierd, here's my 'Harvest"
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Internal Icons
From PHM Plus tools
[Edited: Created imges instead of links !]
vijay: naw, I was just checking to see if there would be an appropriate "Task Manager"-ish icon in there for a TaskMan shortcut for another thread Figured I'd use your utility to have it have a go at it, but went through -65535 with no luck
jpiek: yeah, I know there's tons of icon packs out there, but then the user would have had to download those first
ZeBoxx said:
vijay: naw, I was just checking to see if there would be an appropriate "Task Manager"-ish icon in there for a TaskMan shortcut for another thread Figured I'd use your utility to have it have a go at it, but went through -65535 with no luck
jpiek: yeah, I know there's tons of icon packs out there, but then the user would have had to download those first
Click to expand...
Click to collapse
No, have a look at the internal ones, their great for 'normal' system icons !!
Could someone upload the icon dll from phm tools?? I don't seem to have it... or any other dll etc with some decent icons in (I'm particuly after a bluetooth one, maybe ir, to use with VJVolubilis and PHM tray launch)
I host the PHM tools on my website. Pull the dll from there:
http://www.vijay555.com/vj/!Tools/PHMTools.zip
V
Philippe's site is back online as well, btw - so you could download direct:
http://www.phm.lu/products/PocketPC/
Other solution:
get the program "start menu manager pro 1.2"
With this util you can select a folder, and click on "change icon"
select a source (for instance a dll) end you get a visual of all icons.
Tap your favorite, and your icon is set...
4 dummies, too easy!
p.s.
trial doesn't allow this... so start googling...
If you have a QVGA Smartphone like the HTC Vox / s710, you know well enough that most existing games and other graphics-based Smartphone apps (Windows Mobile 6 Standard) out there only use a postage-stamp sized screen area. An example of this is PDAMill’s Flux Challenge, which, being designed for the traditional low-res (176*220) Smartphone resolution, only uses part of the available QVGA screen estate:
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
There were no widely known solutions for the problem. Some developers announced support for QVGA devices (for example, that of Cell Doom – see announcement HERE), but the most (including PDAMill) didn’t.
Fortunately, an excellent White Russian coder has come up with a generic solution, which not only makes it possible to run MANY (but not all!) games at full screen, but, in cases, also lets for using real (!) QVGA resolution with some titles (for example, emulators).
Downloading, installing
Go to this MoDaCo thread and download the ZIP file attached to the first post. You’ll need to register as a forum user if you aren’t able to access it. If you don’t want to bother with it, I’ve also uploaded the file to my database back-end; it’s HERE.
After this, just unZIP it and start GxQvga Patcher.exe. Should you encounter an error message complaining about the lack of the .NET Framework 2, you will need to download it HERE (note that some stated it only requires 1.1. I haven’t checked whether they’re right. The latter is accessible HERE.)
Using
This patcher app runs on the desktop, NOT on the Smartphone. This means you must transfer the main EXE file of the game / emulator / app you’d like to make use of the QVGA screen to your desktop computer first. To do this, use for example Total Commander with the CE file system patch (see THIS for an explanation of installing it) or, if you don’t want to bother, just the “Explore” button of ActiveSync.
Transfer the main EXE files (but nothing else) of the apps / games you’d like to patch to the directory of where the above-mentioned, just decompressed GxQvga Patcher.exe resides.
Now, start GxQvga Patcher.exe. It will present you a dialog:
In there, click “Select exe file to patch...". Now, select the EXE file you’d like to patch:
After letting it go on, you’ll be presented a message telling you the patching was successful:
Now, all you need to do is:
Copy the patched EXE file back to your MS Smartphone, making sure you overwrite the original EXE file
Go to the QVGA subdirectory on your desktop (just under the directory where GxQvga Patcher.exe resides), and copy XG.dll to the same directory on your smartphone
Start the game / app to see whether it worked; answer Yes to the message.
If the game / app still only uses 176*220 (and not the full screen), exit it and go to the SCALE (NOT the previous QVGA!) subdirectory on your desktop, and copy XG.dll to the same directory on your smartphone and copy XG.dll to the smartphone, making sure you overwrite the previously copied QVGA XG.dll. Now, start the game on your Smartphone. Hope it’ll use the full screen. If it still doesn’t do this, then, nothing can help, I’m afraid.
Examples of the before-after cases
PocketHobbitSP2003 (as of the current, Alpha 11 version) doesn’t support QVGA devices. As can be seen in the following screenshot, without patching, it only uses a stamp-size screen area in Portrait mode on QVGA devices:
http://www.winmobiletech.com/062007C64Emus/c64EmuDefaultStamp.bmp.png
After the patch and using the QVGA DLL, it becomes much bigger and, what is even more important, makes use of the full horizontal screen reoslution – that is, 240 pixels, resulting in MUCH more readable text:
http://www.winmobiletech.com/062007C64Emus/PatchedSEQVGAP.bmp.png
Incidentally, with the SCALE DLL, it also fills in the entire screen horizontally, BUT only upscaling the original, 176*132 rendition resulting in a MUCH inferiour real resolution & readability:
http://www.winmobiletech.com/062007C64Emus/PatchedSPVersionScaleDLLQVGAPortrait.bmp.png
This is why I’ve emphasized you MUST give a try to the QVGA DLL first and only give a try to the SCALE one when the former doesn’t deliver any results.
Recommended link
This MoDaCo thread discusses the converter at length. A MUST!
what about jar games?
Firstly, this only works on the HTC Leo, and secondly, I can't be held responsible if your device catches fire or any other damages caused by using this...
This is probably easier for C++/Win32 devs to get to grips with and I don't know much .Net so I won't be porting this to .Net.
Registry settings
These register the window for multitouch messages
Under HKLM\Software\HTC\TouchGL\Pinch\WhiteList create a key with whatever you want. Within that, create a string called "ClassName" with the Class.
For example:
Code:
HKLM\Software\HTC\TouchGL\Pinch\WhiteList\MultiTouch
ClassName="MULTITOUCH"
That should be all you need... For debugging, I cheated and set my application to have the class HTCAlbumClass. Don't do that if you want it to work on a real device though!
Code
The actual multitouch part is pretty easy to handle.
Your window will get sent two messages, one for multitouch move/begin and one for multitouch end, they're standard C++/Win32 window messages.
Code:
#define WM_MT_BEGIN (WM_APP+16391) // begins multitouch, and is sent when either mouse position changes.
#define WM_MT_END (WM_APP+16392) // ends multitouch
The messages are fairly similar to ones for other mouse events, except that instead of the LPARAM being the mouse co-ordinates, both the LPARAM and the WPARAM are.
Code:
POINT pt,pt2;
pt.x = LOWORD(lParam);
pt.y = HIWORD(lParam);
pt2.x=LOWORD(wParam);
pt2.y=HIWORD(wParam);
In the l3v5yMultiTouch.h file, I've added two functions
Code:
POINT ParamToPoint(WPARAM);
POINT ParamToPoint(LPARAM);
These make converting between window messages and useful data slightly easier...
I've also created a class for MultiTouch that I'm looking to extend with gestures and some neat things. For now, download the source code and give it a play with.
My class also swaps the two points if one goes to the left of the other, so there are no issues with the two points swapping over when you really don't want it to...
Also note that I've now changed the license to GPL v3. If you want to do anything with the code let me know and I'll probably say "yes". This is more to make sure the people that have put work in to this get recognised than anything else.
All you have to do is handle those two points, and handle those two events.
There are two videos of this in action here and I'm working on a paint like application using it...
Attached is a demo application (make sure that HTCAlbum is shut before running it as it uses the HTCAlbum class) and source code.
If you find this useful, please link back to here, and mention my name! (and if you feel really generous, donate as well, but that's completely optional)
A more robust way (and the correct way) to get the values for the messages is:
MilaCzeque said:
This is not true. Message numbers are assigned dynamically and you missed first message.
Right approach is:
Code:
int HTC_Zoom_Begin;
int HTC_Zooming;
int HTC_Zoom_End;
void register_messages()
{
HTC_Zoom_Begin = RegisterWindowMessage(TEXT("HTC_Zoom_Begin"));
HTC_Zoom_End = RegisterWindowMessage(TEXT("HTC_Zoom_End"));
HTC_Zooming = RegisterWindowMessage(TEXT("HTC_Zooming"));
}
Fact that your application works after SR is just coincidence. But nice try anyway.
Click to expand...
Click to collapse
Also note the first message...
I've also realised there are a few different "modes" will find them all, and build a library with a few gestures for things like rotate, pinch zoom, two finger scrolling etc.
saw your tweet & entry @ WMPU, gonna try it now. A huge thanks for this, well done!
Edit: its working, not perfect but it works and thats a good achievement.
tibursio said:
saw your tweet & entry @ WMPU, gonna try it now. A huge thanks for this, well done!
Edit: its working, not perfect but it works and thats a good achievement.
Click to expand...
Click to collapse
What ain't perfect about it?
It might be HTCs fault, or it might be my fault...
Mhh, I cannot get working Windows Messages in .Net
scilor said:
Mhh, I cannot get working Windows Messages in .Net
Click to expand...
Click to collapse
Does http://social.msdn.microsoft.com/Forums/en-US/netfxbcl/thread/7bd3e24f-c21c-4490-910d-b47b6becf70d help?
l3v5y said:
Does http://social.msdn.microsoft.com/Forums/en-US/netfxbcl/thread/7bd3e24f-c21c-4490-910d-b47b6becf70d help?
Click to expand...
Click to collapse
That's for desktop .NET, not the same This, however, should help: http://msdn.microsoft.com/en-us/library/microsoft.windowsce.forms.messagewindow.aspx
cant wait to see the use of multitouch in WM games...Thanks for your effort and releasing the code for others.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
EDIT : Have sent you beer money...
the0ne said:
cant wait to see the use of multitouch in WM games...Thanks for your effort and releasing the code for others.
EDIT : Have sent you beer money...
Click to expand...
Click to collapse
If I manage Multitouch, A Pong Clone will be there
l3v5y, thanks for the findings.
But does it mean that LEO has a dual-touch screen? not really a multi-touch?
How about the normal WM_MOUSE events? But even these exist, it means a tri-touch screen?
P.S. I'm still waiting impatiently for my damn carrier to have HD2 restock...
scilor said:
If I manage Multitouch, A Pong Clone will be there
Click to expand...
Click to collapse
i will hold you to that ...
l3v5y JUST KEEP THE Multitouch Appz coming BABY. Finally
[REF] Multitouch on the HTC Leo
I don't want to hijack this thread, but my 5 year old laptop has multitouch now with ubuntu linux for scrolling. Could it just be a driver issue. I didn't want to start a new thread either, zo just ignore this if you think this is a useless post
l3v5y said:
Code
The actual multitouch part is pretty easy to handle.
Your window will get sent two messages, one for multitouch move/begin and one for multitouch end, they're standard C++/Win32 window messages.
Code:
#define WM_MT_BEGIN (WM_APP+16391) // begins multitouch, and is sent when either mouse position changes.
#define WM_MT_END (WM_APP+16392) // ends multitouch
Click to expand...
Click to collapse
This is not true. Message numbers are assigned dynamically and you missed first message.
Right approach is:
Code:
int HTC_Zoom_Begin;
int HTC_Zooming;
int HTC_Zoom_End;
void register_messages()
{
HTC_Zoom_Begin = RegisterWindowMessage(TEXT("HTC_Zoom_Begin"));
HTC_Zoom_End = RegisterWindowMessage(TEXT("HTC_Zoom_End"));
HTC_Zooming = RegisterWindowMessage(TEXT("HTC_Zooming"));
}
Fact that your application works after SR is just coincidence. But nice try anyway.
MilaCzeque said:
This is not true. Message numbers are assigned dynamically and you missed first message.
Right approach is:
Code:
int HTC_Zoom_Begin;
int HTC_Zooming;
int HTC_Zoom_End;
void register_messages()
{
HTC_Zoom_Begin = RegisterWindowMessage(TEXT("HTC_Zoom_Begin"));
HTC_Zoom_End = RegisterWindowMessage(TEXT("HTC_Zoom_End"));
HTC_Zooming = RegisterWindowMessage(TEXT("HTC_Zooming"));
}
Fact that your application works after SR is just coincidence. But nice try anyway.
Click to expand...
Click to collapse
That makes a lot more sense, though I didn't think of that as the messages sent were always the same, so I assumed they were constants...
Will add what you have found to the first post
I've realised there are a few different "modes" which I'll investigate. I'm also building a library with a few gestures for things like rotate, pinch zoom, two finger scrolling etc. which I'll release the code for all
.Net is done
Edit:
Ok, works, but the Problem is that, PinchToZoom seem to have to BIG Problems:
If 2 Points nearly on one line (horizontal or vertical) they align,
Also the Points are not identifiable
i dont understand
is this proper multitouch or just double scrolling. if it is proper multitouch, will there be a way to have more than dual touch?
It is proper Multitouch, but only 2 Fingers are working with some bugs.
http://scilor.ac-host.net/hd2-leo-real-multitouch.html
(Video is on the way!)
As part of my never ending Weekly Develoment and hacking cleaning up i have moved this thread to Windows Software development.
Sorry L3V5Y for not Pm-ing, didn't want to disturb you since you are a busy guy
will the WP7 support for the old apps of wm?
i know, only market apps, but if we can cook, then we can add a install app existent which install apps, this if the programs have acess to the file system and register.
As far as current information goes, there is no support for legacy software, so I don't think that the libraries necessary for WM6.5 hardware would be on the phone.
Also the window-management (if one wants to call it that) would be completely different in the Windows Phone 7 series.
Another important thing is that it is based on a different kernel than Windows Mobile 6.* (which uses Win CE 5.1). I don't remember what the last number was but it could either be the Win CE 6 Kernel or as was rumored some time ago: the first use of the new Win CE 7 Kernel. This means that lots of API might have changed or be missing.
if we would manage to cook our own custom WP7 ROMs in the future then we also can get us access to the native api. however it won't be possible to run standard wm 6 applications due to GUI components missing. But we still could develop some nice little hacks, tools, services, free customization or maybe even build libraries with native functions exported (to re-use them in the Silverlight apps) to allow us develop something like a simple file explorer, task switcher or registry editor! though not sure about the Silverlight part. What are some .NET experts saying there?
Silverlight and Isolated Storage
When I first read, that there was no direct access to the FileSystem and instead the Silverlight isolated storage was to be used I wondered wether the regular Silverlight Quota's for the isolated storage would apply.
Anyone who wants to know more on what IsoStore quotas are can look for more information here: http://msdn.microsoft.com/en-us/magazine/dd458794.aspx
Suffice to say, that for Silverlight 2 there was a default quota of exactly 1 Megabyte of Storage Space (which could be expanded by querying the user). So I went to find out if this would apply to WP7s Applications as well.
Luckily there are methods for requesting exactlly this information.
This told me that I have: 1 927 Megabytes of free space and that the quota limit is set to the maximum value supported by a long variable - which implies no quota limitation.
The question remains: is this only true of the emulator image or will this apply to the final phones as well (my guess currently is that the 1.9 GB of free space imply 2 gb storage space on the emulator image and ~ 90 mb being used by the system and IE).
I hope somebody thinks this information is useful, I'll perhaps try how much i can fill this memory up and how big my programm can get in memory next.
How do I create 'pages' in VS?
I've downloaded the new VS Express and made a basic GUI app, but I can't figure out how to make pages. Please see my pic below to understand what I am refering to.
Has any one figured this out or seen any guides on how to do this?
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Don't remember where I saw it, but I think pages or "pivots" as they have been called are disabled in this release of the sdk.
Edit - It's on page 57 of the UI Design and Interaction Guide.
Yup it's meant to come in the updated release, also support for Visual Basic
Visual Basic
I just downloaded Windows Phone Developer tools and i can see only support for C#.
Does that means that they are still working on VB part or that they done with VB and i should finally start learning some real programming languages?
check this out... good behavior that works like the panoramic control for that might be released in future versions of the SDK
http://aimeegurl.com/2010/03/18/pan...ne-7-with-no-code/comment-page-1/#comment-966
hope this helps
you know what I'd like to see?
The WP7 homescreen consists of hubs, right? and swiping it to the left, gives you a list of applications. The app list doesn't seems to be finished yet, but how likely will it be, that this page will eventually be made available for UI customization? I mean, the hubs/tiles interface should still be the main screen when getting the phone out of standby, but the app page could an ideal spot for custom UI, just by a swipe of your finger. just a thought.
Quote from the developer forum
Hi folks,
I have some great news!
I received feedback from the GPM for the Microsoft VS Languages team, who indicates:
"there will definitely be support for writing VB apps for Windows Phone 7, but we are still working on the details and the timeline".
Best Regards,
Mark
mrabie said:
http://aimeegurl.com/2010/03/18/pan...ne-7-with-no-code/comment-page-1/#comment-966
hope this helps
Click to expand...
Click to collapse
Cool link!
Yay, i can postpone my VB to C switch
Thx for info
Thanks for pointing out where in the guide it said that. Also thanks to mrabie for that link. I hope the 'pivot' template released with the final version of VS is a simpler though.
You can probably get away with using VB in SL4 using the VB edition of VS2010. Just avoid using any libraries or controls that SL4 doesn't support in WP7. Then when they launch WP7 it will just be a matter of re-making your interface and copy & pasting most of the code.
Beware: I am an idealist
Silverlight limitation \ work around
I was investigating if it was possible to create a Silverlight (SL) application that can help IT people with basic task; ping, trace-route, port scan, viewer HTTP headers, etc. Unfortunately Silverlight doesn't seem to be cable of doing any of this. Very disappointing to learn.
Anyway, the only work around I can in-vision is if a program were to be installed on that network that had all these abilities and then SL could just be used as a remote control. Since many of us in this forum are tech savoy people, I'm curious as to your feelings toward such an application.
Personally, I would use it only as a last resort. I have a similar application for my iphone, but its all self contained on my phone which makes it great when I have to troubleshoot a foreign network.
Possibly you could do the part about an http-header viewer, but as silverlight and XNA currently don't give you access to the ip-stack itself, port-scanner, ping, tracert don't seem possible.
A fact, MS hopefully will address. As to an application which does this from the phone using a proxy: if i have to setup that proxy first, I'd rather stick with that machine for the occasional ping, tracert, too - but that's just me. Nice idea anyway.
Arabic support in the development tools? [Edit: resolved]
Hello
I'm new to WM development and trying to learn on the WM 7 CPT tools released last week. I try to change label text to Arabic characters but they show up as squares. Are the current tools not yet supporting such languages or is there a work around?
On a semi-related note, is anybody else experiencing some lag while playing around the emulator? It just seems quite slow. I'm running on quite a decent PC (quad core, 2gb ram etc).
How would I go about downloading a file?
How would I download a file from the internet onto the phones storage?
I got a text file in mind, and I'd like the text from the file to be displayed in a text box.
So does anyone know how I would go about doing this?
LooperNor said:
How would I download a file from the internet onto the phones storage?
I got a text file in mind, and I'd like the text from the file to be displayed in a text box.
So does anyone know how I would go about doing this?
Click to expand...
Click to collapse
You don't need to download it to the storage device to be able to display a text file from the net. I haven't developed on WP7 yet, but assuming you can use System.Net.dll and System.IO.dll:
C#:
Code:
HttpWebRequest hwr = HttpWebRequest.Create("http://www.google.com/Robots.txt");
WebResponse resp = hwr.GetResponse();
StreamReader sr = new StreamReader(resp.GetResponseStream());
this.textBox1.Text = sr.ReadToEnd();
sr.Close()
edit:
And looking at Scottgu's Twitter code example, you should be able to do:
Code:
private void Form1_Load(object sender,EventArgs e)
{
string url = "http://www.google.com/Robots.txt";
WebClient wc = new WebClient();
wc.DownloadStringCompleted += new DownloadStringCompletedEventHandler(wc_DownloadStringCompleted);
wc.DownloadStringAsync(new Uri(url));
}
void wc_DownloadStringCompleted(object sender, DownloadStringCompletedEventArgs e)
{
if (e.Error != null)
return;
string DownloadedText = e.Result;
this.textBox1.Text = DownloadedText;
}
See post http://forum.xda-developers.com/showthread.php?p=28796038#post28796038 .
Offline javascript, html and html5 loading probably enables much emulators running in WP7 Internet Explorer.
Yes, we can use Silverlight app and IE Engine to run offline html content, but after registry tweak built-in browser can do it.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
I'm still not sure, how emulator will go fast, but it may be equal the original ZX machine.
On my first attempt:
1. Emulator seems to go very slow. I do not know why, hardware is better, then desktop, where the same run very quick.
2. Emulator works with HTC7Pro hardware keyboard. Only "Enter" key does not works
3. Spectrum sometime restarts itself
4. HTML5 emulator version does show nothing on "Spectrum" screen.
News: see http://htc7pro.howto.cz/jsspeccy2/jsspeccy.html from your WP7 device.
Martin7Pro said:
1. Emulator seems to go very slow. I do not know why, hardware is better, then desktop, where the same run very quick.
Click to expand...
Click to collapse
Probably CANVAS tag absention in Internet Explorer and its emulation is too slow. Do you know someboty more about it?
Edit: Canvas is supported in IE9, but very slow rendered. Exists any way?
Martin7Pro said:
2. Emulator works with HTC7Pro hardware keyboard. Only "Enter" key does not works
Click to expand...
Click to collapse
Enter works. "=", "<", ">", "Backspace" etc does not work. I will try remape keys, on-device Spectrum Basic programming is now impossible.
Edit: "Backspace" is "Shift"+"0". "Ctrl" key miss on HTC7Pro, then "=" is impossible without code change. Who idiot makes "Smile" key instead "Ctrl"?
Edit: Line 207: {row: 7, mask: 0x02}, /* fn, HTC7Pro screws up ctrl+key too */ solves it, now I have complete ZX Keyboard with Fn instead Ctrl.
Martin7Pro said:
4. HTML5 emulator version does show nothing on "Spectrum" screen.
Click to expand...
Click to collapse
Some parts work, but Spectrum screen not. It may have simple solution. Do you know someboty more about it?
Edit: Do you understand somebody this code? Error occured in IE9 is: ArrayBuffer and Uint8Array objects are undefined.
is_ie = (typeof ActiveXObject == "function");
if (!is_ie) {
typed_array = ('ArrayBuffer' in window && 'Uint8Array' in window);
if (typed_array && 'mozResponseType' in req) {
/* firefox 6 beta */
req.mozResponseType = 'arraybuffer';
} else if (typed_array && 'responseType' in req) {
/* Chrome */
req.responseType = 'arraybuffer';
} else {
req.overrideMimeType('text/plain; charset=x-user-defined');
typed_array = false;
}
}
MSDN Uint8Array object: Not supported in the following document modes: Quirks, Internet Explorer 6 standards, Internet Explorer 7 standards, Internet Explorer 8 standards, Internet Explorer 9 standards.
Using Phone Commander and its View/Edit feature on-device javascript programming is possible and relatively comfortable.
Bellard's Linux can work, but for Internet Explorer offline loading we must change url request for binaries to javascript including, similarly to Spectrum emulator.
News
1. Both Jsspeccy ZX Spectrum emulator versions work now, include full HTC7Pro HW keyboard support. All HTML5 canvas features are supported (without touching only, must be handled as mouseclick).
2. Speed is unusable now. I mean 5times slowly then original ZX Spectrum. I hope it will solvable. If not, this emulation way is unusable on WP7 phones.
By my deep performance analysis all one frame rendering, keycodes scaning, etc, etc takes cca 4 ms. But, Z80 instructions interpreting for this one frame takes 200-300 ms. It is too much, original frame rate is 50 per sec. On desktop machine the same takes cca 1-3 ms. Is not possible Microsoft does not allowe to take more processor time to running javascript? Or WP7 IE9 has wrong JS algorithms? I mean not, becouse standard JS benchmark gives relatively good results here.
3. I will prepare xap version, usable on all interop unlocked devices (not only fully unlocked custom ROMs as now). May be other XDA people have more experiences with javascript as me and they will able to solve performance problem.
Online WP7 Spectrum emulator
For non-unlocked people I prepared online jsspeccy emulator WP7 port. It is still working very slow, but touch control is fully usable and optimalised for WP7 Mango IE9.
Go (from WP7 device only, it is not properly working from desktop explorers) to http://htc7pro.howto.cz/jsspeccy2/jsspeccy.html
Tap to blue arrow and programm. Any games are under directory picture, but mistake in WP7 IE9 does not allow multitouch using, then playing is much difficult, then on another version, optimalised for my HTC7Pro HW keyboard. You can define "joystick" keys for any games and use taping to game screen. Keys defining is better in landscape mode, all another in portrait mode only. HTC7Pro version (still not published) is working in landscape only. Both version will here for downloading after asking original jsspeccy author. Post experience from doublecore new devices, on my phone is emulating javascript very slow.