WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
74383
Upstream PlatformMouseEvent and LocalizedStrings into WebCore/platform/blackberry
https://bugs.webkit.org/show_bug.cgi?id=74383
Summary
Upstream PlatformMouseEvent and LocalizedStrings into WebCore/platform/blackb...
Mary Wu
Reported
2011-12-13 00:03:22 PST
Upstream PlatformMouseEvent and LocalizedString into WebCore/platform/blackberry: LocalizedStringsBlackBerry.cpp, PlatformMouseEventBlackBerry.cpp
Attachments
Patch
(16.80 KB, patch)
2011-12-13 00:31 PST
,
Mary Wu
no flags
Details
Formatted Diff
Diff
Patch
(16.86 KB, patch)
2011-12-13 18:02 PST
,
Mary Wu
no flags
Details
Formatted Diff
Diff
Patch
(16.85 KB, patch)
2011-12-14 00:20 PST
,
Mary Wu
no flags
Details
Formatted Diff
Diff
Patch
(16.84 KB, patch)
2011-12-14 22:44 PST
,
Mary Wu
no flags
Details
Formatted Diff
Diff
Patch
(15.58 KB, patch)
2011-12-20 19:15 PST
,
Mary Wu
no flags
Details
Formatted Diff
Diff
Show Obsolete
(4)
View All
Add attachment
proposed patch, testcase, etc.
Mary Wu
Comment 1
2011-12-13 00:31:03 PST
Created
attachment 118968
[details]
Patch
Rob Buis
Comment 2
2011-12-13 05:20:58 PST
Comment on
attachment 118968
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=118968&action=review
> Source/WebCore/ChangeLog:10 > + Rob Buis <
rbuis@rim.com
>
I think there were more contributors, for instance I dont think I touched PlatformMouseEvent.
> Source/WebCore/platform/blackberry/LocalizedStringsBlackBerry.cpp:72 > + // however, WebCore wants a '-' (e.g. en_us should read en-us)
Comment should be a sentence.
> Source/WebCore/platform/blackberry/PlatformMouseEventBlackBerry.cpp:36 > + , m_timestamp(WTF::currentTime())
Is the WTF prefix needed?
Rob Buis
Comment 3
2011-12-13 05:21:58 PST
Comment on
attachment 118968
[details]
Patch Clearing r? flag for now, see my comments.
Mary Wu
Comment 4
2011-12-13 18:02:43 PST
Created
attachment 119125
[details]
Patch
Daniel Bates
Comment 5
2011-12-13 18:30:51 PST
Comment on
attachment 119125
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=119125&action=review
> Source/WebCore/platform/blackberry/LocalizedStringsBlackBerry.cpp:24 > +
Nit: I suggest that we remove this empty line as I don't feel it improves the readability of this file.
> Source/WebCore/platform/blackberry/LocalizedStringsBlackBerry.cpp:68 > +String platformDefaultLanguage()
Would it make sense to re-write this function using WTF::String functions instead of using the std::string routines? That is, can we just convert BlackBerry::Platform::Client::get()->getLocale() to a WTF::String then manipulate it as as such? I suggest taking this approach since the WTF::String functions tend to be a bit more concise and at the end of the day we want to return a WTF::String.
> Source/WebCore/platform/blackberry/LocalizedStringsBlackBerry.cpp:71 > + // getLocale() returns a POSIX lcoale which uses '_' to separate language and country
lcoale => locale. country => country.
> Source/WebCore/platform/blackberry/LocalizedStringsBlackBerry.cpp:72 > + // however, we use '-' instead of '_' in WebCore (e.g. en_us should read en-us)
however => However Missing period at the end of this line.
Mary Wu
Comment 6
2011-12-14 00:20:55 PST
Created
attachment 119170
[details]
Patch
Mary Wu
Comment 7
2011-12-14 22:44:16 PST
Created
attachment 119381
[details]
Patch
Daniel Bates
Comment 8
2011-12-15 19:18:20 PST
Comment on
attachment 119381
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=119381&action=review
Thanks Mary for updating the patch. Notice that most of these these methods build a WTF::String object from a C-string. We should probably leak the WTF::String objects if these methods are called frequently instead of building a WTF::String object on each method call.
> Source/WebCore/platform/blackberry/LocalizedStringsBlackBerry.cpp:587 > +}
Do we need to use String::fromUTF8 here? It seems like it would be sufficient to write this as: return String(", ...");
Daniel Bates
Comment 9
2011-12-15 19:20:13 PST
Comment on
attachment 119381
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=119381&action=review
> Source/WebCore/platform/blackberry/LocalizedStringsBlackBerry.cpp:586 > + return String::fromUTF8(", ...");
I meant to add the "return String(", ...");" remark to this line.
Mary Wu
Comment 10
2011-12-15 23:51:34 PST
(In reply to
comment #8
)
> (From update of
attachment 119381
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=119381&action=review
> > Thanks Mary for updating the patch. Notice that most of these these methods build a WTF::String object from a C-string. We should probably leak the WTF::String objects if these methods are called frequently instead of building a WTF::String object on each method call. >
yes, thanks for the comments...those are used in file buttons and context menu which we seldom used, and looks other portings didn't leak WTF::String objects either. So I think maybe we could keep it is here for now.
Mary Wu
Comment 11
2011-12-20 19:15:40 PST
Created
attachment 120135
[details]
Patch
Daniel Bates
Comment 12
2011-12-20 20:42:57 PST
Comment on
attachment 120135
[details]
Patch Thanks for the updated patch.
WebKit Review Bot
Comment 13
2011-12-20 23:36:44 PST
Comment on
attachment 120135
[details]
Patch Clearing flags on attachment: 120135 Committed
r103391
: <
http://trac.webkit.org/changeset/103391
>
WebKit Review Bot
Comment 14
2011-12-20 23:36:49 PST
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug