1. 29 Sep, 2014 17 commits
  2. 28 Sep, 2014 7 commits
  3. 27 Sep, 2014 16 commits
    • brettw's avatar
      Convert GN's deps iterator to work with range-based for loops. · a09df11a
      brettw authored
      Reworks DepsIterator so it is compatible with STL iterators enough to work with range-based for loops. The iterator is now created by a target rather than taking a target as an argument, which makes the loops more natural.
      
      I also changed some loops around code I was touching to use range-based.
      
      Review URL: https://codereview.chromium.org/610043002
      
      Cr-Commit-Position: refs/heads/master@{#297122}
      a09df11a
    • danakj's avatar
      cc: Remove use of PassAs() and constructor-casting with scoped_ptr. · f446a070
      danakj authored
      Say you have class A and subclass B.
      
      Previously it was required to PassAs() a scoped_ptr<B> into a
      scoped_ptr<A>. This is no longer needed, so just use Pass(). For newly
      created scoped_ptrs, you can just use make_scoped_ptr always now.
      
      And when you want to return or assign an empty scoped_ptr(), you can
      now use nullptr directly.
      
      Also adds PRESUBMIT checks for:
      - return scoped<T>(foo). This should be return make_scoped_ptr(foo).
      - bar = scoped<T>(foo). This should be return bar = make_scoped_ptr(foo).
      - return scoped<T>(). This should be return nullptr.
      - bar = scoped<T>(). This should be return bar = nullptr.
      
      This also replaces p.reset() with p = nullptr; But it does not add a
      PRESUBMIT check for that because there are things other than scoped_ptr
      with a reset() function.
      
      R=enne@chromium.org
      
      Committed: https://crrev.com/7bb3dbede19d87f0338797756ffd738adc6bca08
      Cr-Commit-Position: refs/heads/master@{#297096}
      
      Review URL: https://codereview.chromium.org/609663003
      
      Cr-Commit-Position: refs/heads/master@{#297121}
      f446a070
    • John Abd-El-Malek's avatar
      fix build again · ea60a8e7
      John Abd-El-Malek authored
      Review URL: https://codereview.chromium.org/609103002
      
      Cr-Commit-Position: refs/heads/master@{#297120}
      ea60a8e7
    • viettrungluu's avatar
      Mojo: Convert OVERRIDE -> override in mojo/{embedder,system}. · b7776df0
      viettrungluu authored
      R=jamesr@chromium.org
      
      Review URL: https://codereview.chromium.org/611733002
      
      Cr-Commit-Position: refs/heads/master@{#297119}
      b7776df0
    • John Abd-El-Malek's avatar
      fix build. · c174bd4c
      John Abd-El-Malek authored
      Review URL: https://codereview.chromium.org/612643002
      
      Cr-Commit-Position: refs/heads/master@{#297118}
      c174bd4c
    • John Abd-El-Malek's avatar
      Disable CertLoaderTest and NetworkCertMigratorTest tests in debug builds as they time out. · 21ff00fc
      John Abd-El-Malek authored
      BUG=418369
      TBR=zelidrag@chromium.org
      
      Review URL: https://codereview.chromium.org/613553002
      
      Cr-Commit-Position: refs/heads/master@{#297117}
      21ff00fc
    • danakj's avatar
      Add nullptr support to scoped_ptr. · a9527ce3
      danakj authored
      This adds support to use nullptr to construct, assign, or return a
      scoped_ptr<T> and scoped_ptr<T[]>. Support for this requires the use
      of a move-only constructor.
      
      The changes are:
      
      - Add a constructor that takes decltype(nullptr) as a parameter. This
      allows behaviour such as scoped_ptr<T>(nullptr), but also allows a
      function with return type scoped_ptr<T> to "return nullptr;" instead
      of "return scoped_ptr<T>();".
      
      - Add an operator=(decltype(nullptr)) that resets the scoped_ptr to
      empty and deletes anything it held.
      
      - Add/Modify a constructor to take a scoped_ptr<U,E>&& parameter for
      constructing a scoped_ptr from another using move-only semantics. This
      piece is critical for allowing the function returning nullptr to be
      assigned to some other scoped_ptr at the callsite. In particular, take
      the following code:
        scoped_ptr<T> Function() { return nullptr; }
        scoped_ptr<T> var = Function();
      In this case the constructor which takes a nullptr allows Function() to
      be written, but not to be used. The move-only constructor allows the
      assignment from Function() to var. See "C++11 feature proposal:
      Move-only constructors" on chromium-dev for more explanation why.
      
      The scoped_ptr<T> class already had a constructor which took
      scoped_ptr<U,E> as an argument, so this was changed to be
      scoped_ptr<U,E>&& instead. The scoped_ptr<T[]> class had no such
      constructor, so a scoped_ptr&& constructor was added. These match
      the constructors found on the unique_ptr class.
      
      - Remove the RValue type and the contructor that constructs a
      scoped_ptr from an RValue. Change Pass() to return a scoped_ptr&&
      instead of a scoped_ptr::RValue, to avoid the type conversion and
      remove some complexity. This is done with a new emulation macro that
      still provides Pass() and makes the type go down the MoveOnlyType
      path in base::Callback code.
      
      This adds base_unittests to demonstrate and use these changes.
      
      The use of Pass() remains unchanged until std::move() is written
      or allowed. At that time std::move() could be used instead of Pass.
      
      R=brettw@chromium.org, jamesr@chromium.org
      
      Committed: https://crrev.com/2299e91d3508f8d5d18ef990cf6024ea4371250a
      Cr-Commit-Position: refs/heads/master@{#297072}
      
      Review URL: https://codereview.chromium.org/599313003
      
      Cr-Commit-Position: refs/heads/master@{#297116}
      a9527ce3
    • danakj's avatar
      Use reset() to delete the contents of a scoped_ptr, not Pass(). · d4c67a01
      danakj authored
      R=cmumford@chromium.org, jsbell@chromium.org, michaeln@chromium.org
      BUG=418297
      
      Review URL: https://codereview.chromium.org/594403005
      
      Cr-Commit-Position: refs/heads/master@{#297115}
      d4c67a01
    • thestig's avatar
      Printing: Take the PDF rotation into account when printing on Mac. · 23fe5177
      thestig authored
      Derived from worksheet attached to https://code.google.com/p/chromium/issues/detail?id=369206#c17
      
      BUG=369206
      TEST=Manual, see bug.
      
      Review URL: https://codereview.chromium.org/611693002
      
      Cr-Commit-Position: refs/heads/master@{#297114}
      23fe5177
    • gunsch's avatar
      Chromecast: adds Android switches for media playback. · c264a056
      gunsch authored
      Since Cast disables all user interaction, gesture requirement/infobar are
      not useful.
      
      The other flags are for protected content playback.
      
      R=xhwang@chromium.org,byungchul@chromium.org
      BUG=400876
      
      Review URL: https://codereview.chromium.org/597813002
      
      Cr-Commit-Position: refs/heads/master@{#297113}
      c264a056
    • yukishiino's avatar
      linux: Fixes a racy crash by key input at termination. · 1291d0c2
      yukishiino authored
      It seems that it's possible that GDK events happen while we're going
      to unregister the GDK event handler, and the code must be thread-safe.
      (A gpointer |data| in the old code seems pointing to the deleted object.)
      
      This CL removes use of |data| pointer and makes the code thread-safe
      without adding any mutex.
      
      BUG=417210
      
      Review URL: https://codereview.chromium.org/610523002
      
      Cr-Commit-Position: refs/heads/master@{#297112}
      1291d0c2
    • amistry's avatar
      Suppress the exception thrown when responding to message with no response callback. · bd3ad7a6
      amistry authored
      BUG=414483
      
      Review URL: https://codereview.chromium.org/587153002
      
      Cr-Commit-Position: refs/heads/master@{#297111}
      bd3ad7a6
    • brianderson's avatar
      cc: Add trace events to track main thread latency mode · bca35e18
      brianderson authored
      This will make easy to tell when the main thread is
      in a high latency mode without having to infer based
      on the surrounding context.
      
      BUG=none
      
      Review URL: https://codereview.chromium.org/561043002
      
      Cr-Commit-Position: refs/heads/master@{#297110}
      bca35e18
    • dcheng's avatar
      Revert of Mojo: Convert scoped_ptr<...>() to nullptr in mojo/embedder.... · 76577a68
      dcheng authored
      Revert of Mojo: Convert scoped_ptr<...>() to nullptr in mojo/embedder. (patchset #1 id:1 of https://codereview.chromium.org/606143003/)
      
      Reason for revert:
      scoped_ptr nullptr support was reverted.
      
      Original issue's description:
      > Mojo: Convert scoped_ptr<...>() to nullptr in mojo/embedder.
      >
      > R=jamesr@chromium.org
      >
      > Committed: https://crrev.com/1b198fa11edbe68701e12c27d5f4981398f5ca71
      > Cr-Commit-Position: refs/heads/master@{#297093}
      
      TBR=jamesr@chromium.org,viettrungluu@chromium.org
      NOTREECHECKS=true
      NOTRY=true
      
      Review URL: https://codereview.chromium.org/593313006
      
      Cr-Commit-Position: refs/heads/master@{#297109}
      76577a68
    • dcheng's avatar
      Revert of Mojo: Convert some scoped_ptr<...>(new ...) to make_scoped_ptr(new... · 3f8f6ea2
      dcheng authored
      Revert of Mojo: Convert some scoped_ptr<...>(new ...) to make_scoped_ptr(new ...) in mojo/{embedder,system}. (patchset #2 id:20001 of https://codereview.chromium.org/610083002/)
      
      Reason for revert:
      scoped_ptr nullptr support was reverted.
      
      Original issue's description:
      > Mojo: Convert some scoped_ptr<...>(new ...) to make_scoped_ptr(new ...) in mojo/{embedder,system}.
      >
      > R=jamesr@chromium.org
      >
      > Committed: https://crrev.com/a60566701028a7344d17826076780eeb84b63052
      > Cr-Commit-Position: refs/heads/master@{#297095}
      
      TBR=jamesr@chromium.org,viettrungluu@chromium.org
      NOTREECHECKS=true
      NOTRY=true
      
      Review URL: https://codereview.chromium.org/609033002
      
      Cr-Commit-Position: refs/heads/master@{#297108}
      3f8f6ea2
    • dcheng's avatar
      Revert of Add nullptr support to scoped_ptr. (patchset #7 id:180001 of... · 3e0ecf44
      dcheng authored
      Revert of Add nullptr support to scoped_ptr. (patchset #7 id:180001 of https://codereview.chromium.org/599313003/)
      
      Reason for revert:
      This CL broke several scoped_ptr tests.
      
      Original issue's description:
      > Add nullptr support to scoped_ptr.
      >
      > This adds support to use nullptr to construct, assign, or return a
      > scoped_ptr<T> and scoped_ptr<T[]>. Support for this requires the use
      > of a move-only constructor.
      >
      > The changes are:
      >
      > - Add a constructor that takes decltype(nullptr) as a parameter. This
      > allows behaviour such as scoped_ptr<T>(nullptr), but also allows a
      > function with return type scoped_ptr<T> to "return nullptr;" instead
      > of "return scoped_ptr<T>();".
      >
      > - Add an operator=(decltype(nullptr)) that resets the scoped_ptr to
      > empty and deletes anything it held.
      >
      > - Add/Modify a constructor to take a scoped_ptr<U,E>&& parameter for
      > constructing a scoped_ptr from another using move-only semantics. This
      > piece is critical for allowing the function returning nullptr to be
      > assigned to some other scoped_ptr at the callsite. In particular, take
      > the following code:
      >   scoped_ptr<T> Function() { return nullptr; }
      >   scoped_ptr<T> var = Function();
      > In this case the constructor which takes a nullptr allows Function() to
      > be written, but not to be used. The move-only constructor allows the
      > assignment from Function() to var. See "C++11 feature proposal:
      > Move-only constructors" on chromium-dev for more explanation why.
      >
      > The scoped_ptr<T> class already had a constructor which took
      > scoped_ptr<U,E> as an argument, so this was changed to be
      > scoped_ptr<U,E>&& instead. The scoped_ptr<T[]> class had no such
      > constructor, so a scoped_ptr&& constructor was added. These match
      > the constructors found on the unique_ptr class.
      >
      > - Remove the RValue type and the contructor that constructs a
      > scoped_ptr from an RValue. Change Pass() to return a scoped_ptr&&
      > instead of a scoped_ptr::RValue, to avoid the type conversion and
      > remove some complexity. This is done with a new emulation macro that
      > still provides Pass() and makes the type go down the MoveOnlyType
      > path in base::Callback code.
      >
      > This adds base_unittests to demonstrate and use these changes.
      >
      > The use of Pass() remains unchanged until std::move() is written
      > or allowed. At that time std::move() could be used instead of Pass.
      >
      > R=brettw@chromium.org, jamesr@chromium.org
      >
      > Committed: https://crrev.com/2299e91d3508f8d5d18ef990cf6024ea4371250a
      > Cr-Commit-Position: refs/heads/master@{#297072}
      
      TBR=brettw@chromium.org,jamesr@chromium.org,thakis@chromium.org,danakj@chromium.org
      NOTREECHECKS=true
      NOTRY=true
      
      Review URL: https://codereview.chromium.org/603353005
      
      Cr-Commit-Position: refs/heads/master@{#297107}
      3e0ecf44