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

Side by Side Diff: media/tools/player_wtl/props.h

Issue 5682008: Make members of Singleton<T> private and only visible to the singleton type. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 10 years 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. Use of this 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. Use of this
2 // source code is governed by a BSD-style license that can be found in the 2 // source code is governed by a BSD-style license that can be found in the
3 // LICENSE file. 3 // LICENSE file.
4 4
5 #ifndef MEDIA_TOOLS_PLAYER_WTL_PROPS_H_ 5 #ifndef MEDIA_TOOLS_PLAYER_WTL_PROPS_H_
6 #define MEDIA_TOOLS_PLAYER_WTL_PROPS_H_ 6 #define MEDIA_TOOLS_PLAYER_WTL_PROPS_H_
7 7
8 #include "media/tools/player_wtl/movie.h" 8 #include "media/tools/player_wtl/movie.h"
9 9
10 #include "resource.h" 10 #include "resource.h"
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 if (find_handle != INVALID_HANDLE_VALUE) { 117 if (find_handle != INVALID_HANDLE_VALUE) {
118 // TODO(fbarchard): Support files larger than 2 GB 118 // TODO(fbarchard): Support files larger than 2 GB
119 int size_k = (find_data.nFileSizeLow / 1024); 119 int size_k = (find_data.nFileSizeLow / 1024);
120 if (size_k == 0 && find_data.nFileSizeLow != 0) 120 if (size_k == 0 && find_data.nFileSizeLow != 0)
121 size_k = 1; 121 size_k = 1;
122 wchar_t szBuff[100]; 122 wchar_t szBuff[100];
123 wsprintf(szBuff, L"%i KB", size_k); 123 wsprintf(szBuff, L"%i KB", size_k);
124 SetDlgItemText(IDC_FILESIZE, szBuff); 124 SetDlgItemText(IDC_FILESIZE, szBuff);
125 125
126 // TODO(fbarchard): We need a pipeline property for frame rate. 126 // TODO(fbarchard): We need a pipeline property for frame rate.
127 float duration = media::Movie::get()->GetDuration(); 127 float duration = media::Movie::GetInstance()->GetDuration();
128 float fps = 29.97f; 128 float fps = 29.97f;
129 wsprintf(szBuff, L"%i.%2i Seconds, %i Frames", 129 wsprintf(szBuff, L"%i.%2i Seconds, %i Frames",
130 static_cast<int>(duration), 130 static_cast<int>(duration),
131 static_cast<int>(duration * 100) % 100, 131 static_cast<int>(duration * 100) % 100,
132 static_cast<int>(duration * fps)); 132 static_cast<int>(duration * fps));
133 SetDlgItemText(IDC_FILEDURATION, szBuff); 133 SetDlgItemText(IDC_FILEDURATION, szBuff);
134 134
135 SYSTEMTIME st; 135 SYSTEMTIME st;
136 ::FileTimeToSystemTime(&find_data.ftCreationTime, &st); 136 ::FileTimeToSystemTime(&find_data.ftCreationTime, &st);
137 ::GetDateFormat(LOCALE_USER_DEFAULT, 0, &st, 137 ::GetDateFormat(LOCALE_USER_DEFAULT, 0, &st,
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
316 BEGIN_MSG_MAP(CBmpProperties) 316 BEGIN_MSG_MAP(CBmpProperties)
317 CHAIN_MSG_MAP(CPropertySheetImpl<CBmpProperties>) 317 CHAIN_MSG_MAP(CPropertySheetImpl<CBmpProperties>)
318 END_MSG_MAP() 318 END_MSG_MAP()
319 319
320 CPageOne page1_; 320 CPageOne page1_;
321 CPageTwo page2_; 321 CPageTwo page2_;
322 CPageThree page3_; 322 CPageThree page3_;
323 }; 323 };
324 324
325 #endif // MEDIA_TOOLS_PLAYER_WTL_PROPS_H_ 325 #endif // MEDIA_TOOLS_PLAYER_WTL_PROPS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698