tools/resources/find_unused_resources.py
def GetScaleDirectories(resources_path):
  """Returns a list of paths to per-scale-factor resource directories.

  Assumes the directory names end in '_percent', for example,
  ash/resources/default_200_percent or
  chrome/app/theme/resources/touch_140_percent

  Args:
    resources_path: The base path of interest.

  Returns:
    A list of paths relative to the 'src' directory.
  """
  file_list = os.listdir(resources_path)
  scale_directories = []
  for file_entry in file_list:
    file_path = os.path.join(resources_path, file_entry)
    if os.path.isdir(file_path) and file_path.endswith('_percent'):
      scale_directories.append(file_path)

  scale_directories.sort()
  return scale_directories
Returns a list of paths to per-scale-factor resource directories.

  Assumes the directory names end in '_percent', for example,
  ash/resources/default_200_percent or
  chrome/app/theme/resources/touch_140_percent

  Args:
    resources_path: The base path of interest.

  Returns:
    A list of paths relative to the 'src' directory.
  
Returns a list of paths to per-scale-factor resource directories.
Returns a list of paths to per - scale - factor resource directories .
def GetScaleDirectories(resources_path):
  file_list = os.listdir(resources_path)
  scale_directories = []
  for file_entry in file_list:
    file_path = os.path.join(resources_path, file_entry)
    if os.path.isdir(file_path) and file_path.endswith('_percent'):
      scale_directories.append(file_path)
  scale_directories.sort()
  return scale_directories
def GetScaleDirectories ( resources_path ) : file_list = os . listdir ( resources_path ) scale_directories = [ ] for file_entry in file_list : file_path = os . path . join ( resources_path , file_entry ) if os . path . isdir ( file_path ) and file_path . endswith ( '_percent' ) : scale_directories . append ( file_path ) scale_directories . sort ( ) return scale_directories
Returns a list of paths to per-scale-factor resource directories.
Returns a list of paths to per - scale - factor resource directories .
"""Returns a list of paths to per-scale-factor resource directories.

  Assumes the directory names end in '_percent', for example,
  ash/resources/default_200_percent or
  chrome/app/theme/resources/touch_140_percent

  Args:
    resources_path: The base path of interest.

  Returns:
    A list of paths relative to the 'src' directory.
  """
A list of paths relative to the 'src' directory.
A list of paths relative to the ' src ' directory .
resources_path
The base path of interest.
The base path of interest .