~kubuntu-members/korundum/4.11

« back to all changes in this revision

Viewing changes to qtruby/modules/qwt/qwt.rb

  • Committer: Ian Monroe
  • Date: 2010-11-21 15:55:01 UTC
  • Revision ID: git-v1:c37670e4e3c59f5eb2ba112f5341a5e706217f6f
Split up Smoke into Qt and KDE directories. 
Move libsmoke stuff into the generator directory
Split up Ruby into qtruby and korundum directories

svn path=/trunk/KDE/kdebindings/ruby/; revision=1199320

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/usr/bin/ruby
 
2
 
 
3
require 'Qt4'
 
4
 
 
5
module Qwt
 
6
    module Internal
 
7
        def self.init_all_classes
 
8
            Qt::Internal::add_normalize_proc(Proc.new do |classname|
 
9
                if classname =~ /^Qwt/
 
10
                    now = classname.sub(/^Qwt?(?=[A-Z])/,'Qwt::')
 
11
                end
 
12
                now
 
13
            end)
 
14
            getClassList.each do |c|
 
15
                classname = Qt::Internal::normalize_classname(c)
 
16
                id = Qt::Internal::findClass(c);
 
17
                Qt::Internal::insert_pclassid(classname, id)
 
18
                Qt::Internal::cpp_names[classname] = c
 
19
                klass = Qt::Internal::isQObject(c) ? Qt::Internal::create_qobject_class(classname, Qwt) \
 
20
                                                    : Qt::Internal::create_qt_class(classname, Qwt)
 
21
                Qt::Internal::classes[classname] = klass unless klass.nil?
 
22
            end
 
23
        end
 
24
    end
 
25
end