代码之家  ›  专栏  ›  技术社区  ›  Rakesh

黑莓手机中的疑点

  •  0
  • Rakesh  · 技术社区  · 15 年前

    //创建调用

    Invocation invocation =
          new Invocation(filePath,null,BlackBerryContentHandler.ID_MEDIA_CONTENT_HANDLER);
    
        // Get the registry object
           Registry registry = Registry.getRegistry("net.rim.device.api.content.BlackBerryContentHandler");//here i changed to my own file
    
        //Invoke the content handler.
           registry.invoke(invocation);
    

    当应用程序运行时,它导航到媒体应用程序屏幕,但它只是停留在那里,不能播放音乐或媒体文件,有什么问题吗?

    耙齿柄

    1 回复  |  直到 15 年前
        1
  •  0
  •   Vivart    15 年前

    我试过这个代码,它对我很好

    Invocation invocation = new Invocation("file:///SDCard/B.mp3",
                            null, BlackBerryContentHandler.ID_MEDIA_CONTENT_HANDLER);
    Registry.getRegistry(getClass().getName()).invoke(invocation);