Skip to content

Commit

Permalink
Remove code to handle bogus themes. We've had a theming system for a …
Browse files Browse the repository at this point in the history
…while and don't care about people who manually hack the DLLs.

BUG=50107
TEST=none
Review URL: http://codereview.chromium.org/3071002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53715 0039d316-1c4b-4281-b951-d872f2087c98
  • Loading branch information
pkasting@chromium.org committed Jul 26, 2010
1 parent 3b45c6b commit 7cf4d55
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 33 deletions.
6 changes: 0 additions & 6 deletions chrome/app/generated_resources.grd
Original file line number Diff line number Diff line change
Expand Up @@ -4672,12 +4672,6 @@ Keep your key file in a safe place. You will need it to create new versions of y
<message name="IDS_UPGRADE_ERROR" desc="Status label: Error occurred during upgrade">
Update server not available (error: <ph name="ERROR_NUMBER">$1<ex>1</ex></ph>)
</message>
<message name="IDS_RESOURCE_ERROR" desc="Error loading resource">
An error was encountered while loading a program resource. Try reinstalling.
</message>
<message name="IDS_RESOURCE_ERROR_CAPTION" desc="Error loading resource caption">
Resource Error
</message>

<!-- Print -->
<message name="IDS_DEFAULT_PRINT_DOCUMENT_TITLE" desc="Default title for a print document">
Expand Down
27 changes: 0 additions & 27 deletions chrome/browser/views/tabs/base_tab.cc
Original file line number Diff line number Diff line change
Expand Up @@ -508,27 +508,6 @@ void BaseTab::InitResources() {
loading_animation_frame_count =
loading_animation_frames->width() / loading_animation_frames->height();

// We get a DIV0 further down when the throbber is replaced by an image which
// is taller than wide. In this case we cannot deduce an animation sequence
// from it since we assume that each animation frame has the width of the
// image's height.
if (loading_animation_frame_count == 0) {
#ifdef WIN32
// TODO(idanan): Remove this when we have a way to handle theme errors.
// See: http://code.google.com/p/chromium/issues/detail?id=12531 For now,
// this is Windows-specific because some users have downloaded a DLL from
// outside of Google to override the theme.
std::wstring text = l10n_util::GetString(IDS_RESOURCE_ERROR);
std::wstring caption = l10n_util::GetString(IDS_RESOURCE_ERROR_CAPTION);
UINT flags = MB_OK | MB_ICONWARNING | MB_TOPMOST;
win_util::MessageBox(NULL, text, caption, flags);
#endif
CHECK(loading_animation_frame_count) <<
"Invalid throbber size. Width = " <<
loading_animation_frames->width() << ", height = " <<
loading_animation_frames->height();
}

waiting_animation_frames = rb.GetBitmapNamed(IDR_THROBBER_WAITING);
DCHECK(waiting_animation_frames);
DCHECK(waiting_animation_frames->width() %
Expand All @@ -538,12 +517,6 @@ void BaseTab::InitResources() {

waiting_to_loading_frame_count_ratio =
waiting_animation_frame_count / loading_animation_frame_count;
// TODO(beng): eventually remove this when we have a proper themeing system.
// themes not supporting IDR_THROBBER_WAITING are causing this
// value to be 0 which causes DIV0 crashes. The value of 5
// matches the current bitmaps in our source.
if (waiting_to_loading_frame_count_ratio == 0)
waiting_to_loading_frame_count_ratio = 5;

font_ = new gfx::Font(rb.GetFont(ResourceBundle::BaseFont));
font_height_ = font_->height();
Expand Down

0 comments on commit 7cf4d55

Please sign in to comment.