Commit graph

107 commits

Author SHA1 Message Date
Nicholas Nethercote
b71747b2ac Bug 1299727 - Rename NS_WARN_IF_FALSE as NS_WARNING_ASSERTION. r=erahm.
The new name makes the sense of the condition much clearer. E.g. compare:

  NS_WARN_IF_FALSE(!rv.Failed());

with:

  NS_WARNING_ASSERTION(!rv.Failed());

The new name also makes it clearer that it only has effect in debug builds,
because that's standard for assertions.

--HG--
extra : rebase_source : 886e57a9e433e0cb6ed635cc075b34b7ebf81853
2016-09-01 15:01:16 +10:00
Kit Cambridge
2aee7885cb Bug 1285408 - Add change source tracking for bookmarks. r=markh
MozReview-Commit-ID: I6IWhMWR1bG

--HG--
extra : rebase_source : b331e448871e44ee51923b4c512e0b8ad4206cd4
2016-08-11 13:13:22 -07:00
Nathan Froyd
a5dd4da994 Bug 1292301 - reduce reference-counting in Places; r=adw
By using nsCOMArray::Forget, we can pass the references we hold in an
nsCOMArray directly to the XPCOM caller, without having to go through an
extra cycle of AddRef/Release calls.  This way should be slightly faster
and it also results in smaller code.  Notice that we don't have to worry
about removing the OOM check in the places that use Forget(), because we
were already using moz_xmalloc to allocate the outparam array, and
moz_xmalloc aborts the process on OOM, just as Forget() does.

The nsNavHistoryFolderResultNode::GetQueries change is thrown in for fun.
2016-08-05 22:03:44 -04:00
Marco Bonardo
3837320431 Bug 889561 - Reduce the size of places.sqlite by removing the url unique index from moz_places. r=adw
MozReview-Commit-ID: 2kxaXnUYIwT

--HG--
extra : rebase_source : bbcaf85a0346b5347fc94053b4f193e4b89f2995
2016-06-29 14:47:36 +02:00
Carsten "Tomcat" Book
a982df321d Backed out changeset ceff61c9fc5a (bug 889561) for frequent testfailures on pgo in /bookmarks/test_
--HG--
extra : rebase_source : 84d364e67739738da807b9d83c3338ebd8a086a6
2016-06-29 13:54:51 +02:00
Marco Bonardo
67c3ad7930 Bug 889561 - Reduce the size of places.sqlite by removing the url unique index from moz_places. r=adw
MozReview-Commit-ID: 2kxaXnUYIwT

--HG--
extra : rebase_source : e03928033aa795c9a1cdb34d4f4618b0eb1d6890
2016-06-20 13:22:10 +02:00
Marco Bonardo
41b74693db Bug 1277235 - add typed and visitCount to onVisit. r=adw
MozReview-Commit-ID: 3XfBCiOgyAu

--HG--
extra : rebase_source : 9f98a7a838e4ac56ae82bd13c330f181268228e5
2016-06-01 16:42:15 +02:00
Kris Maglione
0c9d76f23e Bug 1277405: Clear Places observers at XPCOM shutdown. r=mak
MozReview-Commit-ID: 6JYMX7TXDLZ

--HG--
extra : rebase_source : e3828d8cc57246ef2633dc7d7ef7145437f2ebf6
extra : amend_source : 702d193f2cb0ad02a578bc4b07b9ea94e43f2ce6
2016-06-01 16:47:34 -07:00
Kris Maglione
2327dbb60e Bug 1269398: Add visitType, visitId, and fromVisitId fields to history visit query results. r=mak
MozReview-Commit-ID: BCsztVsCH98

--HG--
extra : rebase_source : 5f0ae7221b1107d3a0a7de8d7b702fbb897adef4
2016-05-13 13:47:24 -07:00
Kyle Huey
d9265a3eaf Bug 1259294: Part 2 - Use MOZ_ALWAYS_SUCCEEDS. r=froydnj 2016-03-28 10:28:15 -07:00
Marco Bonardo
43b99cedf6 Bug 1240013 - Crash in nsNavBookmarks::OnVisit by setting long location.hash. r=Yoric
--HG--
extra : commitid : 22HsGbBqJ8f
extra : rebase_source : 9b7794cc6d81f8de6c43b303779835f06eca7271
2016-01-26 18:43:53 +01: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
Marco Bonardo
ddb1ecd87c Bug 1150678 - Part 1: notify the old value in onItemChanged (only URI changes for now). r=ttaubert
--HG--
extra : commitid : KYeXHLc1S0W
2015-08-05 23:10:11 +02:00
Wes Kocher
c906ee5d44 Backed out 2 changesets (bug 1150678) for xpcshell bustage
Backed out changeset 1c24d237080c (bug 1150678)
Backed out changeset 9f1f1e11ca37 (bug 1150678)
2015-08-05 16:24:58 -07:00
Marco Bonardo
0aae79f32c Bug 1150678 - Part 1: notify the old value in onItemChanged (only URI changes for now). r=ttaubert
--HG--
extra : commitid : L3Sje2jJyiY
2015-08-05 23:10:11 +02:00
Andrew McCreight
058dc9a336 Bug 1189369, part 2 - Don't implicitly convert nsMaybeWeakPtr to an nsCOMPtr. r=mak
This is only used in a few places, and it obscures what is happening.
2015-08-04 13:55:01 -07:00
Birunthan Mohanathas
a8939590de Bug 1182996 - Fix and add missing namespace comments. rs=ehsan
The bulk of this commit was generated by running:

  run-clang-tidy.py \
    -checks='-*,llvm-namespace-comment' \
    -header-filter=^/.../mozilla-central/.* \
    -fix
2015-07-13 08:25:42 -07:00
Eric Rahm
1175adb068 Bug 1175249 - Silence warning about possibly slow query to moz_bookmarks. r=dietrich
Add comment ot disable potential slow query warning. The odds that more than one
bookmark for a URI is returned seems pretty low, the odds that there are enough
to warrant an index seems even lower.
2015-06-16 15:24:46 -07:00
Marco Bonardo
648bd5431e Bug 1140395 - Deprecate old keywords API. r=ttaubert 2015-05-05 15:40:09 +02:00
Mike Hommey
b077d9624d Bug 1134920 - Use moz_xmalloc/moz_xrealloc/free instead of nsMemory::Alloc/Realloc/Free. r=nfroyd 2015-04-01 13:51:45 +09:00
Marco Bonardo
05596be753 Bug 1125115 - Write a new keywords pseudo-API in PlacesUtils. r=ttaubert 2015-03-20 09:39:25 +01:00
Marco Bonardo
941b1d7ea2 Bug 1125113 - Change the keywords schema associating them with uris. r=ttaubert 2015-03-20 09:39:20 +01:00
Nicholas Nethercote
242708cf72 Bug 1127201 (attempt 2, part 1) - Replace most NS_ABORT_IF_FALSE calls with MOZ_ASSERT. r=Waldo.
--HG--
extra : rebase_source : 488e401ff87e31a2074c4108c4df0572d9536667
2015-02-09 14:34:50 -08:00
Andrew McCreight
d3826daa16 Back out Bug 1127201 (part 2) for various problems. 2015-02-06 15:04:32 -08:00
Nicholas Nethercote
d34f0301b8 Bug 1127201 (part 2) - Convert all NS_ABORT_IF_FALSE calls to MOZ_ASSERT. r=Waldo.
--HG--
extra : rebase_source : 99182e70335d2b5ff95f8c528ae992d37294be3a
2015-02-04 20:05:36 -08:00
Asaf Romano
db963fd7aa Bug 1107308 - Round dateAdded and lastModified values to milliseconds precision in places cpp components. r=mak 2014-12-04 14:09:48 -08:00
Asaf Romano
40a4768f10 Bug 1105866 - Implement folderShorcutNode.targetFolderGuid (guid version of folderShortcutNode.folderItemId). r=mak 2014-12-10 19:03:15 +02:00
Marco Bonardo
b81685e028 Backout ce637f8721d3 (bug 1083469) due to failures with old autocomplete enabled. a=bustage on CLOSED TREE 2014-11-27 00:00:23 +01:00
Marco Bonardo
8d53fcb53e Bug 1083469 - Allow to use old keywords APIs along with Bookmarks.jsm r=mano
--HG--
extra : rebase_source : 606724d24ed36d9de8045f526d1bb452bf5d0530
2014-11-24 00:51:32 +01:00
Tim Taubert
4c199ab4c3 Bug 1083462 - Remove the bookmarks cache r=mak 2014-11-11 17:52:31 +01:00
Marco Bonardo
0cab188e85 Bug 1071505 - use constant GUIDs for Places roots. r=mano 2014-11-04 17:40:33 +01:00
Akshendra Pratap
567a7beec4 Bug 1064365 - Deprecated GetKeywordForURI. r=mak 2014-10-31 06:35:00 +01:00
Marco Bonardo
5806a38580 Bug 1081099 - Implement bookmarks notifications from Bookmarks.jsm. r=mano 2014-10-25 19:18:59 +02:00
Asaf Romano
d83f8d60e1 Bug 1068671 - folderReadOnly doesn't pertain to bookmarks or results. r=mak 2014-10-14 17:03:28 +03:00
Carsten "Tomcat" Book
459781f902 Backed out changeset b30d47d94a85 (bug 1068671) for bc1 test failures 2014-10-01 13:14:06 +02:00
Asaf Romano
896f516dd7 Bug 1068671 - Remove 'read-only' folders support from places. r=mak 2014-10-01 12:19:06 +03:00
Nicholas Nethercote
a7cf4142b4 Bug 1050009 - Initialize pldhash tables with a length, not a capacity. r=roc.
* * *
imported patch rm-dummy-params

--HG--
extra : rebase_source : c25987eb11bae197218d5fc53b77def19afa36ac
2014-08-06 06:31:21 -07:00
Victor Porof
9ce7e9c089 Bug 1007203 - Always add categories when pushing to the pseudostack, r=djvj 2014-05-23 17:12:29 -04:00
Birunthan Mohanathas
0e6f3a6562 Bug 869836 - Part 3: Use Append('c') instead of AppendLiteral("c"). r=ehsan 2014-05-22 06:48:51 +03:00
Birunthan Mohanathas
5f1fde8824 Bug 900908 - Part 3: Change uses of numbered macros in nsIClassInfoImpl.h/nsISupportsImpl.h to the variadic variants. r=froydnj 2014-04-27 03:06:00 -04:00
Drew Willcoxon
eceebb9622 Bug 911307 - Reflect changes to top sites immediately in about:newtab (part 1, Places patch). r=mak 2014-03-28 23:30:04 -07:00
Phil Ringnalda
128149306e Backed out 2 changesets (bug 911307) for frequent timeouts in browser_newtab_perwindow_private_browsing.js
Backed out changeset 70638b7c97f1 (bug 911307)
Backed out changeset 3951f7e82b4c (bug 911307)
2014-03-29 12:13:11 -07:00
Drew Willcoxon
56944f3c4b Bug 911307 - Reflect changes to top sites immediately in about:newtab (part 1, Places patch). r=mak 2014-03-28 23:30:04 -07:00
Robert O'Callahan
15468267dc Bug 955889. Restore caching in EnsureKeywordsHash. r=mano
--HG--
extra : rebase_source : 41847499e245b5e3073dfa1a8ebeb2f9451b802b
2014-01-04 18:14:27 +13:00
Ehsan Akhgari
1b83407ce9 Bug 927728 - Part 1: Replace PRUnichar with char16_t; r=roc
This patch was automatically generated by the following script:

#!/bin/bash
# Command to convert PRUnichar to char16_t

function convert() {
echo "Converting $1 to $2..."
find . ! -wholename "*nsprpub*" \
       ! -wholename "*security/nss*" \
       ! -wholename "*modules/libmar*" \
       ! -wholename "*/.hg*" \
       ! -wholename "obj-ff-dbg*" \
       ! -name prtypes.h \
       ! -name Char16.h \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.c" \
         -o -iname "*.cc" \
         -o -iname "*.idl" \
         -o -iname "*.ipdl" \
         -o -iname "*.ipdlh" \
         -o -iname "*.mm" \) | \
    xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}

convert PRUnichar char16_t
2014-01-04 10:02:17 -05:00
Birunthan Mohanathas
68b00083fd Bug 713082 - Part 1: Remove unnecessary Util.h includes. r=Waldo 2013-12-08 21:52:33 -05:00
Asaf Romano
bd6038d32e Bug 914687 - API for presetting GUIDs on bookmarks. r=mak. sr=gavin 2013-11-19 17:13:27 +02:00
Robert O'Callahan
03e7828db2 Bug 910989. Remove nsTHashtable::Init, fallible allocation, and MT hashtables. r=ehsan,bsmedberg
--HG--
extra : rebase_source : 0787130b1814c74bfb38dc178de94022f0b2e64e
2013-09-02 20:41:57 +12:00
Raymond Lee
075f79d3a3 Bug 627487 - Bookmark JSON backup should contain new-style GUIDs. r=mano 2013-09-03 11:56:25 +08:00
Benoit Girard
042e2c83ad Bug 851611 - Part 3: Rename headers. r=jrmuizel
--HG--
rename : tools/profiler/sampler.h => tools/profiler/GeckoProfiler.h
rename : tools/profiler/sps_sampler.h => tools/profiler/GeckoProfilerImpl.h
extra : rebase_source : 6ea7c660764a4390cdd8dd91561fff1d7bad6035
2013-03-18 15:25:50 +01:00