问题描述:
今天新建的iOS6项目添加Three20类库,报错,如下:
/Three20/src/Three20UI/Sources/UIViewAdditions.m:109:5: Unknown type name '_tapCount'; did you mean 'ItemCount'?
/Three20/src/Three20UI/Sources/UIViewAdditions.m:109:15: Expected identifier or '('
/Three20/src/Three20UI/Sources/UIViewAdditions.m:110:5: Use of undeclared identifier '_locationInWindow'
/Three20/src/Three20UI/Sources/UIViewAdditions.m:111:5: Use of undeclared identifier '_previousLocationInWindow'
/Three20/src/Three20UI/Sources/UIViewAdditions.m:113:43: Use of undeclared identifier '_locationInWindow'
/Three20/src/Three20UI/Sources/UIViewAdditions.m:114:5: Use of undeclared identifier '_view'; did you mean 'view'?
/Three20/src/Three20UI/Sources/UIViewAdditions.m:115:5: Use of undeclared identifier '_window'
/Three20/src/Three20UI/Sources/UIViewAdditions.m:116:5: Use of undeclared identifier '_phase'
/Three20/src/Three20UI/Sources/UIViewAdditions.m:117:5: Use of undeclared identifier '_touchFlags'
/Three20/src/Three20UI/Sources/UIViewAdditions.m:118:5: Use of undeclared identifier '_touchFlags'
/Three20/src/Three20UI/Sources/UIViewAdditions.m:119:5: Use of undeclared identifier '_timestamp'
/Three20/src/Three20UI/Sources/UIViewAdditions.m:127:3: Use of undeclared identifier '_phase'; did you mean 'phase'?
/Three20/src/Three20UI/Sources/UIViewAdditions.m:128:3: Use of undeclared identifier '_timestamp'
问题解决:
在UIViewAdditions.m文件中:
#ifdef DEBUG
改为:
#ifdef DEBUG_TOUCHES