myutils.py 文件源码

python
阅读 26 收藏 0 点赞 0 评论 0

项目:darkc0de-old-stuff 作者: tuwid 项目源码 文件源码
def main_is_frozen():
    return (hasattr(sys, "frozen") or # new py2exe
            hasattr(sys, "importers") or # old py2exe
            imp.is_frozen("__main__")) # tools/freeze


#~ if __name__ == '__main__':
    #some test code here. 
    #~ def hello(name="bla"):
        #~ print "hello, ", name

    #~ myt = MyTimer(1.0, 5, hello, ["bob"])
    #~ myt.start()
    #~ time.sleep(4)
    #~ myt.cancel()
    #~ print "next timer"
    #~ myt = MyTimer(1.0, 0, hello, ["bob"])
    #~ myt.start()
    #~ time.sleep(6)
    #~ myt.cancel()
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号