Oct 11 | 9:55 AM |
Mark M. | has entered the room |
Mark M. | turned on guest access |
Gabriele | has entered the room |
Mark M. |
howdy, Gabriele!
|
Mark M. |
how can I help you today?
|
Oct 11 | 10:00 AM |
Gabriele |
Hi :)
|
Oct 11 | 10:00 AM |
Gabriele |
I've moved as you told me the webview things to webviewhelper and it looks much better, logically talking!
|
Gabriele |
View paste
|
Mark M. |
I cannot tell you what is "best"
|
Mark M. |
if your adapter needs to know when
onPageFinished() is invoked, either it needs to be the WebViewClient
(and therefore implements the method) or it needs to be called by
something else that is the WebViewClient
|
Gabriele |
Hm, which is a good way to implement something
that, when onPageFinished is fired inside MyWebViewClient, it sends a
"signal" to the adapter?
|
Mark M. |
I cannot tell you "which is a good way"
|
Gabriele |
A way* :P
|
Mark M. |
either MyWebViewClient holds onto the adapter, or it holds onto something that holds onto the adapter
|
Mark M. |
if you wish, define a custom interface for your event, have the adapter implement that interface
|
Oct 11 | 10:05 AM |
Mark M. |
and have MyWebViewClient call methods on that interface
|
Gabriele |
Ah, ok. I will try with interfaces, thank you.
|
Gabriele |
For some reason, after I moved the webview to the
new class, I've implemented methods to get the current title and the
current url (getTitle and getUrl)
|
Gabriele |
But getTitle is working and getUrl is returning null! Have you an idea of why this is happening?
|
Gabriele |
I'm calling getTitle and getUrl together, in the same method.
|
Gabriele | |
Mark M. |
are you loading the content into the WebView from loadUrl()?
|
Gabriele | |
Gabriele |
One is working and one not. TT
|
Oct 11 | 10:10 AM |
Mark M. |
are you loading the content into the WebView from loadUrl()?
|
Gabriele |
yes
|
Mark M. |
are there any redirects, or JavaScript code, that might change what the content is?
|
Mark M. |
(in a way that might mess up the URL the WebView thinks the content is coming from)
|
Mark M. |
also, when are you calling getUrl()? from onPageFinished(), or earlier?
|
Gabriele |
I've tried calling it after onPageFinished(),
(async from it, anyway); there are not redirects, some js code, but it
is from wikipedia
|
Mark M. |
then I do not know why it might be null
|
Mark M. |
OTOH, if there are no redirects, it should be the same value you passed to loadUrl()
|
Mark M. |
so you should already have that data
|
Gabriele |
Yes, exactly
|
Gabriele |
I've also tried tapping on a link inside wikipedia, but it's returning null, too. Maybe some stupid error in my code
|
Oct 11 | 10:15 AM |
Mark M. |
possibly, but IMHO it is more likely something odd with WebView
|
Gabriele |
Oh, ok thank you. I will do some try! :P
|
Oct 11 | 10:20 AM |
Mark M. |
if you have another question, feel free to ask
|
Gabriele |
Ok, thank you.
|
Oct 11 | 10:55 AM |
Roy | has entered the room |
Mark M. |
howdy, Roy!
|
Mark M. |
the chat is nearly over -- do you have a quick question?
|
Roy |
Hi I had a quick question on SQl Cipher
|
Mark M. |
go ahead
|
Roy |
Can I have a database without the cipher with a db
for a cipher. I just need to put the usernames password in encrypted
mode but others as open
|
Mark M. |
the encryption is at the database level, not by table
|
Mark M. |
you are welcome to use two databases, though, one using SQLCipher and one note
|
Mark M. |
er, not
|
Roy |
ok
|
Roy |
Thanks
|
Roy | has left the room |
Oct 11 | 11:00 AM |
Mark M. |
and, with that, today's chat is over
|
Mark M. |
next one is 4pm Eastern on Tuesday
|
Mark M. |
have a pleasant day!
|
Gabriele | has left the room |
Mark M. | turned off guest access |