Can the Android drawable directory contain subdirectories?

后端 未结 21 1335
醉梦人生
醉梦人生 2020-11-22 04:13

In the Android SDK documentation, all of the examples used with the @drawable/my_image xml syntax directly address images that are stored in the res/drawable directory in my

21条回答
  •  半阙折子戏
    2020-11-22 04:36

    #!/usr/bin/env ruby
    
    # current dir should be drawable-hdpi/ etc
    
    # nuke all symlinks
    Dir.foreach('.') {|f|
        File.delete(f) if File.symlink?(f)
    }
    
    # symlink all resources renaming with underscores
    Dir.glob("**/*.png") {|f|
        system "ln -s #{f} #{f.gsub('/', '_')}" if f.include?("/")
    }
    

提交回复
热议问题