maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   [Announce] Macuco(2) on n900 - "iphone faker" browser (https://talk.maemo.org/showthread.php?t=51487)

hschmitt 2010-08-06 10:47

Re: [Announce] Macuco(2) on n900 - "iphone faker" browser
 
Quote:

Originally Posted by fcrochik (Post 776492)
I would really like to figure out how to disable the "auto complete" before promoting it. It is quite annoying....

Why do you ask? Do you think it could still be useful as it is?

I think it is, but would be even better when fixed.
Aren't there other Qt projects, that fixed this problem?
I am trying to ask all projects in Extras-testing that are promotable.
Your app is only a few days promotable, but there are apps that wait 4 weeks for the maintainer to do a action.
If you think the app is not in the shape to go to Extras repository then you should vote with thump down, which will remove the package from Extras-testing.

fcrochik 2010-08-06 11:55

Re: [Announce] Macuco(2) on n900 - "iphone faker" browser
 
Quote:

Originally Posted by hschmitt (Post 777650)
I think it is, but would be even better when fixed.
Aren't there other Qt projects, that fixed this problem?

I don't know of any other qt/maemo5/webkit projects

Quote:

Originally Posted by hschmitt (Post 777650)
I am trying to ask all projects in Extras-testing that are promotable.
Your app is only a few days promotable, but there are apps that wait 4 weeks for the maintainer to do a action.
If you think the app is not in the shape to go to Extras repository then you should vote with thump down, which will remove the package from Extras-testing.

I think the application is useful as it is but it is quite annoying... I will think about it some more... suggestions with this regard from the current users are welcome.

hschmitt 2010-08-06 12:25

Re: [Announce] Macuco(2) on n900 - "iphone faker" browser
 
Quote:

Originally Posted by fcrochik (Post 777716)
I don't know of any other qt/maemo5/webkit projects


I think the application is useful as it is but it is quite annoying... I will think about it some more... suggestions with this regard from the current users are welcome.

Maybe a troll from Qt team has a hint? Their bugtracker is open. You should ask them.

fcrochik 2010-08-06 14:34

Re: [Announce] Macuco(2) on n900 - "iphone faker" browser
 
Quote:

Originally Posted by hschmitt (Post 777740)
Maybe a troll from Qt team has a hint? Their bugtracker is open. You should ask them.

Martin just pointed out to me that this is a known bug: http://bugreports.qt.nokia.com/browse/QTBUG-12171

I will see if I can find a work around for this bug or to make the qt4.7 version work and then will promote the package. If nothing else I want to make sure that this project can have a new version soon that works before promoting the existing one to extras.

hschmitt 2010-08-07 14:47

Re: [Announce] Macuco(2) on n900 - "iphone faker" browser
 
Quote:

Originally Posted by fcrochik (Post 777856)
Martin just pointed out to me that this is a known bug: http://bugreports.qt.nokia.com/browse/QTBUG-12171

I will see if I can find a work around for this bug or to make the qt4.7 version work and then will promote the package. If nothing else I want to make sure that this project can have a new version soon that works before promoting the existing one to extras.

And there is the change, that should do it but does not:
Code:

#ifdef Q_WS_MAEMO_5
// Maemo 5 MicroB Browser disables auto-uppercase and predictive text, thus, so do we.
webPageClient->setInputMethodHint(Qt::ImhNoAutoUppercase, true);
webPageClient->setInputMethodHint(Qt::ImhNoPredictiveText, true);
#endif // Q_WS_MAEMO_5

Can you get hold of the object and try to set it again?

fcrochik 2010-08-07 16:45

Re: [Announce] Macuco(2) on n900 - "iphone faker" browser
 
Quote:

Originally Posted by hschmitt (Post 778803)
And there is the change, that should do it but does not:
Code:

#ifdef Q_WS_MAEMO_5
// Maemo 5 MicroB Browser disables auto-uppercase and predictive text, thus, so do we.
webPageClient->setInputMethodHint(Qt::ImhNoAutoUppercase, true);
webPageClient->setInputMethodHint(Qt::ImhNoPredictiveText, true);
#endif // Q_WS_MAEMO_5

Can you get hold of the object and try to set it again?

On a quick inspection of the code it seems that I can't... The "d" on the code bellow is private and I could not find any method that exposes it even to a class that inherits it.

Code:

QWebPageClient* webPageClient = m_page->d->client;
(*) m_page is a QWebPage object

The only I can think of would be to recompile the qtwebkit module but that would create another set of problems... Do you know of any other way or have any other ideas?

Felipe

daperl 2010-08-07 17:59

Re: [Announce] Macuco(2) on n900 - "iphone faker" browser
 
Quote:

Originally Posted by fcrochik (Post 778900)
On a quick inspection of the code it seems that I can't... The "d" on the code bellow is private and I could not find any method that exposes it even to a class that inherits it.

Code:

QWebPageClient* webPageClient = m_page->d->client;
(*) m_page is a QWebPage object

The only I can think of would be to recompile the qtwebkit module but that would create another set of problems... Do you know of any other way or have any other ideas?

Felipe

For now, why not just cast using fake data types where d and client are the same bytes away as in the private data types. Or even better, just copy, paste and rename the private data types. The following compiles:

Code:

typedef struct {
  int z;
} QWebPageClient;

typedef struct {
  int *zi;
  QWebPageClient *client;
} d_type;

typedef struct {
  int *zi;
  QWebPageClient *client;
} fake_d_type;

typedef struct {
  long *al;
  d_type *d;
} m_page_type;

typedef struct {
  int *ai;
  fake_d_type *d;
} fake_m_page_type;

main () {

  m_page_type *m_page;
  QWebPageClient *webPageClient;

  webPageClient = ((fake_m_page_type *)m_page)->d->client;

}


daperl 2010-08-07 18:20

Re: [Announce] Macuco(2) on n900 - "iphone faker" browser
 
Woops, redid using classes. Still compiles.

Code:

class QWebPageClient {
  int z;
};

class d_class {
  private:
    int *zi;
    QWebPageClient *client;
};

class fake_d_class {
  public:
    int *zi;
    QWebPageClient *client;
};

class m_page_class {
  private:
    long *al;
    d_class *d;
};

class fake_m_page_class {
  public:
    long *al;
    fake_d_class *d;
};

main () {

  m_page_class *m_page;
  QWebPageClient *webPageClient;

  webPageClient = ((fake_m_page_class *)m_page)->d->client;

}


fcrochik 2010-08-07 19:51

Re: [Announce] Macuco(2) on n900 - "iphone faker" browser
 
Quote:

Originally Posted by daperl (Post 778964)
Woops, redid using classes. Still compiles.

It would be an ugly hack but I tried. Unfortunately didn't work... It seems that I got the fake classes right but calling the method does not affect how the input box behaves... The hints probably get updated every time a input control get the focus.

I would have to change the input hints just after a field get focus and just before the user can start typing.

I will look for some other options... I still think the best way out is to start using Qt4.7 but then we will have other issues.

daperl 2010-08-07 20:44

Re: [Announce] Macuco(2) on n900 - "iphone faker" browser
 
I don't think it got an official port to Maemo 5, but maybe you can take a look at the Arora code. It's a Qt webkit browser that ran well under Maemo 4, and it seems to be a very active project.


All times are GMT. The time now is 21:16.

vBulletin® Version 3.8.8