Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(273)

Side by Side Diff: public/web/WebSpeechGrammar.h

Issue 168963003: Make WebPrivatePtr capable of wrapping garbage collected objects. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Temporarily drop back to using .reset() instead of nullptr. Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * * Redistributions of source code must retain the above copyright 7 * * Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * * Redistributions in binary form must reproduce the above copyright 9 * * Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 WebSpeechGrammar(const WebSpeechGrammar& grammar) { assign(grammar); } 42 WebSpeechGrammar(const WebSpeechGrammar& grammar) { assign(grammar); }
43 ~WebSpeechGrammar() { reset(); } 43 ~WebSpeechGrammar() { reset(); }
44 44
45 BLINK_EXPORT WebURL src() const; 45 BLINK_EXPORT WebURL src() const;
46 BLINK_EXPORT float weight() const; 46 BLINK_EXPORT float weight() const;
47 47
48 BLINK_EXPORT void reset(); 48 BLINK_EXPORT void reset();
49 BLINK_EXPORT void assign(const WebSpeechGrammar&); 49 BLINK_EXPORT void assign(const WebSpeechGrammar&);
50 50
51 #if BLINK_IMPLEMENTATION 51 #if BLINK_IMPLEMENTATION
52 WebSpeechGrammar(const WTF::PassRefPtr<WebCore::SpeechGrammar>&); 52 explicit WebSpeechGrammar(const PassRefPtrWillBeRawPtr<WebCore::SpeechGramma r>&);
53 WebSpeechGrammar& operator=(const WTF::PassRefPtr<WebCore::SpeechGrammar>&); 53 WebSpeechGrammar& operator=(const PassRefPtrWillBeRawPtr<WebCore::SpeechGram mar>&);
54 #endif 54 #endif
55 55
56 private: 56 private:
57 WebPrivatePtr<WebCore::SpeechGrammar> m_private; 57 WebPrivatePtr<WebCore::SpeechGrammar> m_private;
58 }; 58 };
59 59
60 } // namespace blink 60 } // namespace blink
61 61
62 #endif // WebSpeechGrammar_h 62 #endif // WebSpeechGrammar_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698