Media currently has a number of old and unused theme implementations (see @TODO: Needs a major cleanup in media_theme()) which should be removed.

Comments

devin carlson’s picture

Status: Active » Needs review
StatusFileSize
new3.48 KB

A patch to remove all of the unused code.

ParisLiakos’s picture

ok i tested the patch nothing, seems to break.
I am not sure about media_link though. Any insight were this was being used? I found a rederence of it in hook_entity_info_alter which makes me wondering, need to search this more

devin carlson’s picture

StatusFileSize
new35.57 KB

I actually came across that function while trying to solve an issue someone described on IRC.

media_link is used in Media 7.x-1.x to generate a link to a file with a generic file type icon. It's used on the admin/content/media page. I've attached a screenshot of it in use.

With the move to File entity for Media 7.x-2.x the function is no longer necessary (File entity takes care of generating the page).

The reference to media_link in hook_entity_info_alter is unrelated. It adds the additional "link" view mode to files and will actually be removed by #1051090: Revamp file view modes: migrate media_small to teaser, media_large to full, media_preview to preview; deprecate link & original.

ParisLiakos’s picture

Status: Needs review » Fixed

awesome, thanks for the explanation
http://drupalcode.org/project/media.git/commit/49343d2

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.