Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 24

Thread: Creating OMControls (like browser)

  1. #11
    Raw Wave
    Auto Apps:loading...
    justchat_1's Avatar
    Join Date
    Jul 2008
    Location
    Boston, Ma or NY,NY
    Posts
    2,359
    Quote Originally Posted by martin_p View Post
    For Borte: the methods you mentioned are defined only to get and not to set the property, so they should never change these values, unless I didn't understood what you meant.

    For justchat: when I change settings they remain correctly in memory because when I load again the setup panel I see exactly the values I set previously.Also if I exit from OM and re-enter the values are still there.

    But there is no way to convince the main menu button to update with the displayname. Probably something wrong in the cycle "for" or in general in method Setting_Changed, but again very difficult to understand what (how to debug a plugin? Is it possibile to write something in the debug.txt file?)

    A part of this, I cannot make start the application I choose, just an empty panel appear.

    I tried then the embedApplication method in a simpler plugin and it actually works. But the application is not actually embedded but appears like a normal application window over OM, as I started-up by myself. Same thing if I try with external nav plugin.
    Is there a way to actually embed it in the panel without showing borders, similarly to what suggested borte for google inside windows form?
    Is there a way to embed a browser like webBrowser in windows form? How much difficult could be to adapth the geckofx control to fit in OM?

    THanks again for support. For me very precious.
    In OnSettingChanged you need to update the local variable...After this line:
    Code:
    if (s.Name == (m_EmbedAppString + ".DisplayName")):
    Add in something like this:
    Code:
    m_DisplayName = s.Value;

    Also your second for loop should be:
    Code:
    for (int j = 1; j <= 3; j++)
    You wrote:
    Code:
    for (int j = 1; i <= 3; j++)
    The reason the app doesn't start is because you wrote:
    Code:
    m_exe = settings.getSetting(m_EmbedAppString + "");
    instead of:
    Code:
    m_exe = settings.getSetting(m_EmbedAppString + ".Exe");
    Also you wrote:
    Code:
    case eFunction.TransitionToPanel:
                            if (m_Embedded && (arg2 == m_EmbedAppString))
    and it should be:
    Code:
    case eFunction.TransitionToPanel:
                            if (!m_Embedded && (arg2 == m_EmbedAppString))

    edit:
    To write something in the debug log file:
    Code:
    host.sendMessage("OMDebug","YourPluginName","The text you want in the debug log")

  2. #12
    Newbie
    Join Date
    Jan 2011
    Location
    Italy
    Posts
    26
    ok, thanks again for precious help, I think in the week end I will try it and let you know if it works.
    Do you think the embedding in this case will be "integrated" into the UI and not separated window?

  3. #13
    Newbie
    Join Date
    Jan 2011
    Location
    Italy
    Posts
    26
    Now it works, it opens the application but in a separated window.
    Attached the DLL and the code, if you like to put it somewhere as example.

    Is there a way to phisically embed into the UI?
    Attached Files Attached Files

  4. #14
    Raw Wave
    Auto Apps:loading...
    justchat_1's Avatar
    Join Date
    Jul 2008
    Location
    Boston, Ma or NY,NY
    Posts
    2,359
    Move the openMobile window around and you will see that its fully embedded. The window is a resizable window which means it draws its border too...if you want to change the window style you will need to use platform specific API calls such as this on windows:
    http://msdn.microsoft.com/en-us/libr...(v=vs.85).aspx

  5. #15
    Newbie
    Join Date
    Jan 2011
    Location
    Italy
    Posts
    26
    There is something other I need to learn about Win API calls. This is something similar to the example given by Borte, my problem was to get the window handle of the host to embed the google window.
    I will try to play on it.

  6. #16
    Raw Wave
    Auto Apps:loading...
    justchat_1's Avatar
    Join Date
    Jul 2008
    Location
    Boston, Ma or NY,NY
    Posts
    2,359
    theHost.UIHandle(screen) returns the window handle

  7. #17
    Newbie
    Join Date
    Jan 2011
    Location
    Italy
    Posts
    26
    is there a way to cast the type object returned by this method in the int accepted by the SetParent procedure?

  8. #18
    Raw Wave
    Auto Apps:loading...
    justchat_1's Avatar
    Join Date
    Jul 2008
    Location
    Boston, Ma or NY,NY
    Posts
    2,359
    Quote Originally Posted by martin_p View Post
    is there a way to cast the type object returned by this method in the int accepted by the SetParent procedure?
    huh?

    in openMobile you should be using the embedApplication function...that takes screen number as an int. If your talking about the windows SetParent API, that takes an IntPtr not an int... and theHost.UIHandle returns an IntPtr on windows (which you cast from an object)

  9. #19
    Newbie
    Join Date
    Jan 2011
    Location
    Italy
    Posts
    26
    Chat, you help is always precious! But you have to consider that, as my title says, I'm a newbie.
    So yes, I can follow you, but sometime there's something that for you is implicit which for me instead is not.
    Anyway I believe I fixed the problem as casting UIHandle into IntPtr, and then converting to an Int32 with the type method.
    Now google appeared into the menu screen. So now the point is to detect the right screen number of my plug in. THe answer is here around, I'm sure, I only have to find it!
    I'll let you know and as soon as I have the PI working I'll post it.
    Thanks again for your availability.

  10. #20
    Newbie
    Join Date
    Jan 2011
    Location
    Italy
    Posts
    26
    Hi,
    I'm still playing with Google. Here attached what I developed to embed the rendering window directly in a OM panel.
    I know, there is some "workaround" like win form panel and not using the OM embeding application method.
    It's not the right way to code a plug in for OM.
    But it works.
    I have a couple of questions: is there a way to get the maximum useful dimensions of the panel (regardless of this plug-in)?
    How to make the media bar and the volume to overlap to the panel? Probably there is no way if not using OMControls, but.....

    Thanks
    Attached Files Attached Files

Page 2 of 3 FirstFirst 123 LastLast

Similar Threads

  1. Fresh Install on New PC, Rebooting
    By phc in forum StreetDeck
    Replies: 3
    Last Post: 12-23-2007, 09:33 AM
  2. pc reboot on sd startup
    By duanes7 in forum StreetDeck
    Replies: 3
    Last Post: 12-14-2007, 08:55 AM
  3. Holux GPS Trouble
    By mangus580 in forum StreetDeck
    Replies: 34
    Last Post: 11-26-2007, 08:56 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •