Граф коммитов

21 Коммитов

Автор SHA1 Сообщение Дата
JW Wang 755272513a Bug 1316145 - pass DontAssertDispatchSuccess when dispatching events because it is hard to enforce notification happens before AbstractThread shutdown. r=jya
MozReview-Commit-ID: 2SATSQfdskl

--HG--
extra : rebase_source : a9b6cfcb5633f62daa919dc0e3326469d8589837
2016-11-18 17:50:27 +08:00
JW Wang a96557277e Bug 1281090. Part 5 - don't lock while sending synchronous notification to avoid deadlock. r=gerald.
MozReview-Commit-ID: hOasuXLf5a

--HG--
extra : rebase_source : 74b84944360afcd4ea50390153d071c8e63a74b4
2016-06-21 16:32:13 +08:00
JW Wang f972c4f7af Bug 1281090. Part 4 - prune disconnected listeners more aggressively to avoid hitting the assertion. r=gerald.
MozReview-Commit-ID: 1Z5L3swKBx6

--HG--
extra : rebase_source : 05c147239fa97d754439ce1154d34d29c22542df
2016-06-21 16:31:03 +08:00
JW Wang 9c080bdb61 Bug 1281090. Part 2 - add synchronous notification to MediaEventSourceImpl. r=gerald.
MozReview-Commit-ID: 6uWl4IP5iEP

--HG--
extra : rebase_source : 045d7e18650aa4a17c05f35f33fc4fa80e9a030c
2016-06-20 18:31:01 +08:00
JW Wang 7cb843e953 Bug 1281090. Part 1 - rename ListenerMode to ListenerPolicy. r=gerald.
MozReview-Commit-ID: IaRwKRlAoxy

--HG--
extra : rebase_source : 8d438b3c768f2d78b8b62e83e0ab55000d8a7fb7
2016-06-20 16:06:54 +08:00
JW Wang 0618cbfada Bug 1280175 - Allow passing lvalue to MediaEventProducerExc<T>::Notify. r=gerald
MozReview-Commit-ID: 6Wr3obvkVXo

--HG--
extra : rebase_source : 09ae3a471caa065cdf908bf302d56fe33548157d
2016-06-14 15:25:45 +08:00
JW Wang 39a058508a Bug 1278772 - Use value semantics to facilitate compiler optimization. r=kinetik.
MozReview-Commit-ID: 2TAU0GFwasB

--HG--
extra : rebase_source : 4d664e84b15076564ed9ea88163b08712f1f6ca9
2016-06-08 15:26:28 +08:00
Kyle Huey c73656947b Bug 1265927: Move nsRunnable to mozilla::Runnable, CancelableRunnable to mozilla::CancelableRunnable. r=froydnj 2016-04-25 17:23:21 -07:00
JW Wang 45b81db1ac Bug 1233648 - Fix some insufficient includes. r=kinetik. 2015-12-18 15:12:45 +08:00
JW Wang ef41bf18de Bug 1219984. Part 2 - add support for multiple arguments. r=kinetik. 2015-11-02 10:48:01 +08:00
JW Wang eb17eba41a Bug 1219984. Part 1 - remove EventPassMode::Both. In order to support multiple arguments, all arguments must be either moved or copied. r=kinetik. 2015-11-02 10:47:59 +08:00
JW Wang 08767bf029 Bug 1219974 - Add DisconnectIfExists() to MediaEventListener. r=kinetik. 2015-10-30 09:13:10 +08:00
Nathan Froyd 01583602a9 Bug 1207245 - part 6 - rename nsRefPtr<T> to RefPtr<T>; r=ehsan; a=Tomcat
The bulk of this commit was generated with a script, executed at the top
level of a typical source code checkout.  The only non-machine-generated
part was modifying MFBT's moz.build to reflect the new naming.

CLOSED TREE makes big refactorings like this a piece of cake.

 # The main substitution.
find . -name '*.cpp' -o -name '*.cc' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    xargs perl -p -i -e '
 s/nsRefPtr\.h/RefPtr\.h/g; # handle includes
 s/nsRefPtr ?</RefPtr</g;   # handle declarations and variables
'

 # Handle a special friend declaration in gfx/layers/AtomicRefCountedWithFinalize.h.
perl -p -i -e 's/::nsRefPtr;/::RefPtr;/' gfx/layers/AtomicRefCountedWithFinalize.h

 # Handle nsRefPtr.h itself, a couple places that define constructors
 # from nsRefPtr, and code generators specially.  We do this here, rather
 # than indiscriminantly s/nsRefPtr/RefPtr/, because that would rename
 # things like nsRefPtrHashtable.
perl -p -i -e 's/nsRefPtr/RefPtr/g' \
     mfbt/nsRefPtr.h \
     xpcom/glue/nsCOMPtr.h \
     xpcom/base/OwningNonNull.h \
     ipc/ipdl/ipdl/lower.py \
     ipc/ipdl/ipdl/builtin.py \
     dom/bindings/Codegen.py \
     python/lldbutils/lldbutils/utils.py

 # In our indiscriminate substitution above, we renamed
 # nsRefPtrGetterAddRefs, the class behind getter_AddRefs.  Fix that up.
find . -name '*.cpp' -o -name '*.h' -o -name '*.idl' | \
    xargs perl -p -i -e 's/nsRefPtrGetterAddRefs/RefPtrGetterAddRefs/g'

if [ -d .git ]; then
    git mv mfbt/nsRefPtr.h mfbt/RefPtr.h
else
    hg mv mfbt/nsRefPtr.h mfbt/RefPtr.h
fi

--HG--
rename : mfbt/nsRefPtr.h => mfbt/RefPtr.h
2015-10-18 01:24:48 -04:00
JW Wang f6179e5445 Bug 1194112. Part 5 - remove dead code. r=kinetik. 2015-08-24 10:38:37 +08:00
JW Wang 4aed3938f0 Bug 1194112. Part 4 - reimplement Listener/ListenerImpl to support Move. r=kinetik. 2015-08-24 10:38:33 +08:00
JW Wang db0abb5fc0 Bug 1194112. Part 3 - use perfect forwarding in MediaEventProducer::Notify() so MediaEventSource can decide whether to copy or move according to its ListenerMode. r=kinetik. 2015-08-24 10:38:28 +08:00
JW Wang 9904cca471 Bug 1194112. Part 2 - small code refactoring to reduce typing. r=kinetik. 2015-08-24 10:38:24 +08:00
JW Wang 481dca5497 Bug 1194112. Part 1 - extract event dispatch code from ListenerImpl to its own class. r=kinetik. 2015-08-24 10:38:16 +08:00
JW Wang 003fc818b3 Bug 1193117. Add an exclusive mode to allow at most one listener. r=kinetik. 2015-08-14 13:01:03 +08:00
JW Wang 4312487e6f Bug 1192109 - Fix insufficient includes in MediaEventSource.h. r=kinetik. 2015-08-07 11:11:18 +08:00
JW Wang 646d8bce1b Bug 1187214. Part 1 - Implement MediaEventSource. r=kinetik. 2015-07-24 09:03:11 +08:00