Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Type casting QtActivity to customActivity?

Type casting QtActivity to customActivity?

Scheduled Pinned Locked Moved Mobile and Embedded
1 Posts 1 Posters 604 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    jiangcaiyang
    wrote on last edited by
    #1

    I use Qt for Android 5.3 to make a small application.
    I've created a Java class named: CustomActivity extends from QtActivity, the Java code looks like this:
    @public class CustomActivity extends QtActivity
    {
    };@
    In C++ side, we can access the activity through QtAndroid::androidActivity( ) using QtAndroidExtras module. however when I stringify the activity( qDebug( "toString: %s", qPrintable( activity.toString( ) ) ); ), it is not what I desired: CustomActivity, but its super class QtActivity.
    I want to cast it into CustomActivity, how to do that?

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved